diff --git a/delojza.py b/delojza.py index 13608df..ba78084 100755 --- a/delojza.py +++ b/delojza.py @@ -287,10 +287,12 @@ class DelojzaBot: message.reply_text(reply) filenames = download_fn(urls, out_path, message.date, message, audio=audio, filename=filename) - tumblr_ids = [] - if hashtags[0] in ('TUMBLR', 'TUMBLR_NOW') and self.tumblr_client: - now = hashtags[0] == 'TUMBLR_NOW' + cmd_hashtag = hashtags[0] + + tumblr_ids = [] + if cmd_hashtag in ('TUMBLR', 'TUMBLR_NOW') and self.tumblr_client: + now = cmd_hashtag == 'TUMBLR_NOW' reply = '(btw, {})'.format("***FIRING TO TUMBLR RIGHT AWAY***" if now else "queueing to tumblr") message.reply_text(reply, parse_mode=telegram.ParseMode.MARKDOWN) for filename in filenames: