From 4f6a109fe8ab627ee1744769c939e99009373f80 Mon Sep 17 00:00:00 2001 From: shoopea Date: Sat, 4 May 2019 18:43:04 +0800 Subject: [PATCH] parsed --- td.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/td.go b/td.go index 3ca814c..dc5337b 100644 --- a/td.go +++ b/td.go @@ -132,14 +132,14 @@ func getHistory(c *tdlib.Client, chatID64 *int64, senderUserID64 *int64) { lastMsgTime = time.Unix(int64(m.Date), 0) } msgCount = msgCount + 1 - if msgCount%1000 == 0 { - fmt.Printf("Waiting : %d messages retrieved from %s ...\n", msgCount, lastMsgTime.Format(time.RFC3339)) - } - } default: log.Printf("getHistory : no handler for %s\n", msg.Content.GetMessageContentEnum()) } + if msgParsed%1000 == 0 { + fmt.Printf("Waiting : %d messages retrieved from %s ...\n", msgCount, lastMsgTime.Format(time.RFC3339)) + } + } } else { lastMsgID64 = -1