소스 검색

Merge pull request #4 from leothehuman/candidate

Quickfix for /o show and other names longer than 64 characters (ignor…
master
leothehuman 8 년 전
부모
커밋
fb7eece088
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2
    1
      magic-judge-telegram-bot.py

+ 2
- 1
magic-judge-telegram-bot.py 파일 보기

@@ -63,7 +63,8 @@ def oracle_command(bot, update, args):
return

if len(nameCandidates) > 1:
reply_markup = InlineKeyboardMarkup([[InlineKeyboardButton(name, callback_data=name)] for name in nameCandidates])
# TODO: if len(name) < 64 is a quickfix for /o show, which fails to send correct callback data for un... card
reply_markup = InlineKeyboardMarkup([[InlineKeyboardButton(name, callback_data=name)] for name in nameCandidates if len(name) < 64])
update.message.reply_text('Which one?', reply_markup=reply_markup, quote=False)
return


Loading…
취소
저장