コード例 #1
0
ファイル: live.py プロジェクト: warandpeace/lrrbot
def unregister_self(lrrbot, conn, event, respond_to):
    """
	Command: !live unregister

	Unregister your channel as a fanstreamer channel.
	"""
    channel = irc.client.NickMask(event.source).nick.lower()
    yield from twitch.unfollow_channel(channel)
    conn.privmsg(respond_to, "Channel '%s' removed from the fanstreamer list." % channel)
コード例 #2
0
ファイル: live.py プロジェクト: warandpeace/lrrbot
def unregister(lrrbot, conn, event, respond_to, channel):
    """
	Command: !live unregister CHANNEL

	Unregister CHANNEL as a fanstreamer channel.
	"""
    try:
        yield from twitch.unfollow_channel(channel)
        conn.privmsg(respond_to, "Channel '%s' removed from the fanstreamer list." % channel)
    except urllib.error.HTTPError:
        conn.privmsg(respond_to, "'%s' isn't a Twitch channel." % channel)