Skip to content

Commit

Permalink
[admin] Join channels on invite
Browse files Browse the repository at this point in the history
  • Loading branch information
bui committed Aug 23, 2013
1 parent 8153885 commit 7770268
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,18 @@ def me(bot, trigger):
bot.msg(channel, msg)


@willie.module.event('INVITE')
@willie.module.rule('.*')
@willie.module.priority('low')
def invite_join(bot, trigger):
"""
Join a channel willie is invited to, if the inviter is an admin.
"""
if not trigger.admin:
return
bot.write(('JOIN', trigger.args[1]))


@willie.module.event('KICK')
@willie.module.rule(r'.*')
@willie.module.priority('low')
Expand Down

0 comments on commit 7770268

Please sign in to comment.