2
0
mirror of https://github.com/yagop/node-telegram-bot-api synced 2025-08-29 13:27:44 +00:00

allow 0ms for polling interval

This commit is contained in:
brandly 2015-10-18 13:49:41 -04:00
parent 2b58384ba5
commit 152710505f

View File

@ -17,7 +17,7 @@ var TelegramBotPolling = function (token, options, callback) {
this.token = token;
this.callback = callback;
this.timeout = options.timeout || 0;
this.interval = options.interval || 2000;
this.interval = (typeof options.interval === 'number') ? options.interval : 2000;
this.lastUpdate = 0;
this.lastRequest = null;
this.abort = false;