You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using Question and typing an answer instead of tapping a button, invalid promise seems not to work.
varquestion=newQuestion().text('Pick something, do not type').answers([['1'],['2']]).to(message.chat.id);bot.send(question).then(message=>{console.log('Valid Answer:',message.text);if(message.text=='1'){console.log('1 is OK');}elseif(message.text=='2'){console.log('2 is OK');}},message=>{console.log('Invalid:',message.text);});
Do I understand it correctly: if don't tap any button and type something different then Invalid should be logged to console ?
The text was updated successfully, but these errors were encountered:
I've tried reproducing your code @mishachesnokov, all worked exactly like you intended, selecting an answer or typing whitelisted and even unsupported answer worked like your code intended.
When using Question and typing an answer instead of tapping a button, invalid promise seems not to work.
Do I understand it correctly: if don't tap any button and type something different then Invalid should be logged to console ?
The text was updated successfully, but these errors were encountered: