Closed kolasss closed 1 year ago
Hi @kolasss,
why do you want to set interval between polling attempts? And why it should be inside #fetch_updates
? If for some reason you want to customize polling behavior, you can use your own polling loop:
def do_polling(client)
loop do
puts "Polling..."
client.fetch_updates do |message|
puts message.inspect
end
sleep 1
end
end
do_polling(Telegram::Bot::Client.new(token))
@atipugin just a suggestion, I think could be usefull for some people I use interval for 1 second in my code
This PR is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.
set interval for long-polling