Allow tweeting images without caption
This commit is contained in:
parent
a4c560baf2
commit
520fff4402
1 changed files with 11 additions and 8 deletions
|
@ -59,16 +59,19 @@ def captionHelper(bot, update):
|
||||||
else:
|
else:
|
||||||
args = update.message.caption.split()
|
args = update.message.caption.split()
|
||||||
|
|
||||||
if args[0].startswith("/"):
|
try:
|
||||||
try:
|
if args[0].startswith("/"):
|
||||||
feature = commands[args[0][1:]]
|
|
||||||
try:
|
try:
|
||||||
feature(bot, update, args[1:])
|
feature = commands[args[0][1:]]
|
||||||
|
try:
|
||||||
|
feature(bot, update, args[1:])
|
||||||
|
except:
|
||||||
|
feature(bot, update)
|
||||||
except:
|
except:
|
||||||
feature(bot, update)
|
update.message.reply_text(bottools.strings.unknownCommand)
|
||||||
except:
|
else:
|
||||||
update.message.reply_text(bottools.strings.unknownCommand)
|
raise ValueError()
|
||||||
else:
|
except:
|
||||||
explicitTweet(bot, update, args)
|
explicitTweet(bot, update, args)
|
||||||
|
|
||||||
def mentionHelper(bot, update):
|
def mentionHelper(bot, update):
|
||||||
|
|
Loading…
Reference in a new issue