diff --git a/modules/admin.py b/modules/admin.py index 4df833b..f506149 100755 --- a/modules/admin.py +++ b/modules/admin.py @@ -25,6 +25,9 @@ def join(bot, trigger): def part(bot, trigger): """Part the specified channel. This is an admin-only command.""" channel, _, part_msg = trigger.group(2).partition(' ') + if not channel.startswith("#"): + part_msg = channel + channel = "" if not channel: channel = trigger.channel if part_msg: diff --git a/modules/seen.py b/modules/seen.py index d120c82..729764a 100755 --- a/modules/seen.py +++ b/modules/seen.py @@ -58,10 +58,11 @@ def setup(bot): def seen(bot, trigger): """ Reports when and where the user was last/first seen. - --last [-l] reports when the user was last seen. This is the default. - --first [-f] reports when the user was first seen. - --message [-m] includes the first/last message the user sent. - --context [-c] includes irc logs before and after their last message as context. Implies --message. + + -l, --last - reports when the user was last seen. This is the default. + -f, --first - reports when the user was first seen. + -m, --message - includes the first/last message the user sent. + -c, --context - includes irc logs before and after their last message as context. Implies --message. """ if not trigger.group(2): return bot.reply("Seen who?") diff --git a/modules/translate.py b/modules/translate.py index 4c57080..fe66dbc 100755 --- a/modules/translate.py +++ b/modules/translate.py @@ -32,11 +32,16 @@ def translate(text, in_lang='auto', out_lang='en'): @commands('translate', 'tr') -@example('.tr :en :fr my dog', '"mon chien" (en to fr, translate.google.com)') +@example('.tr -i en -o fr my dog', '"mon chien" (en to fr, translate.google.com)') @example('.tr היי', '"Hey" (iw to en, translate.google.com)') @example('.tr mon chien', '"my dog" (fr to en, translate.google.com)') def tr2(bot, trigger): - """Translates a phrase, with an optional language hint.""" + """ + Translates a phrase, with an optional language hint. + + -i LANG, --inlang LANG - specifies the assumed input language. + -o LANG, --outlang LANG - specifies the desired output language. + """ if not trigger.group(2): return bot.reply("Translate what?")