@@ -299,7 +299,7 @@ proc banChatSenderChat*(b: TeleBot, chatId: ChatId, senderChatId: int, untilDate
299
299
300
300
proc unbanChatSenderChat*(b: TeleBot, chatId: ChatId, senderChatId: int ): Future[bool ] {.api, async.}
301
301
302
- proc getUpdates*(b: TeleBot, offset, limit = 0, timeout = 50, allowedUpdates: seq [string ] = @[]): Future[JsonNode] {.async.} =
302
+ proc getUpdates*(b: TeleBot, offset = 0 , limit = 0, timeout = 50, allowedUpdates: seq [string ] = @[]): Future[JsonNode] {.async.} =
303
303
var data = newMultipartData()
304
304
305
305
if offset > 0:
@@ -347,7 +347,7 @@ proc cleanUpdates*(b: TeleBot) {.async.} =
347
347
while updates.len >= 100 :
348
348
updates = await b.getUpdates()
349
349
350
- proc loop(b: TeleBot, timeout = 50 , offset, limit = 0 ) {.async.} =
350
+ proc loop(b: TeleBot, timeout = 50 , offset = 0 , limit = 0 ) {.async.} =
351
351
try :
352
352
let me = waitFor b.getMe()
353
353
b.id = me.id
@@ -366,12 +366,12 @@ proc loop(b: TeleBot, timeout = 50, offset, limit = 0) {.async.} =
366
366
let update = unmarshal(item, Update)
367
367
asyncCheck b.handleUpdate(update)
368
368
369
- proc poll* (b: TeleBot, timeout = 50 , offset, limit = 0 , clean = false ) =
369
+ proc poll* (b: TeleBot, timeout = 50 , offset = 0 , limit = 0 , clean = false ) =
370
370
if clean:
371
371
waitFor b.cleanUpdates()
372
372
waitFor loop(b, timeout, offset, limit)
373
373
374
- proc pollAsync* (b: TeleBot, timeout = 50 , offset, limit = 0 , clean = false ) {.async.} =
374
+ proc pollAsync* (b: TeleBot, timeout = 50 , offset = 0 , limit = 0 , clean = false ) {.async.} =
375
375
if clean:
376
376
await b.cleanUpdates()
377
377
await loop(b, timeout, offset, limit)
@@ -415,3 +415,5 @@ proc reopenGeneralForumTopic*(b: TeleBot, chatId: ChatId): Future[bool] {.api, a
415
415
proc hideGeneralForumTopic* (b: TeleBot, chatId: ChatId): Future[bool ] {.api, async.}
416
416
417
417
proc unhideGeneralForumTopic* (b: TeleBot, chatId: ChatId): Future[bool ] {.api, async.}
418
+
419
+ proc unpinAllGeneralForumTopicMessages* (b: TeleBot, chatId: ChatId): Future[bool ] {.api, async.}
0 commit comments