M
M
mafinpy2021-08-31 17:46:29
Python
mafinpy, 2021-08-31 17:46:29

How to fix 'Dispatcher' object has no attribute 'addTelegramCommandHandler'?

if __name__ == '__main__':
casinobot = DealerBot(TOKEN, ADMIN_USERS, CASINO_CHAT_ID)
updater = Updater(bot=casinobot)
j = updater.job_queue
dispatcher = updater.dispatcher
dispatcher.addTelegramCommandHandler('deposita', buyin) this is where the error starts
612e40740c2bb216453097.png

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
soremix, 2021-08-31
@mafinpy

This method has not been available for 5 years.

dispatcher.add_handler(CommandHandler('deposita', buyin))

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question