mirror of
https://github.com/eternnoir/pyTelegramBotAPI.git
synced 2023-08-10 21:12:57 +03:00
Update README.md
This commit is contained in:
parent
1544efbbda
commit
d5b7c2b49b
@ -59,6 +59,10 @@ def listener(messages):
|
|||||||
tb = telebot.TeleBot(TOKEN)
|
tb = telebot.TeleBot(TOKEN)
|
||||||
tb.set_update_listener(listener) #register listener
|
tb.set_update_listener(listener) #register listener
|
||||||
tb.polling()
|
tb.polling()
|
||||||
|
# polling will not stop when get new message
|
||||||
|
tb.polling(True)
|
||||||
|
# Interval setup. Sleep 3 secs between request new message.
|
||||||
|
tb.polling(True, 3)
|
||||||
|
|
||||||
while True: # Don't let the main Thread end.
|
while True: # Don't let the main Thread end.
|
||||||
pass
|
pass
|
||||||
|
Loading…
Reference in New Issue
Block a user