This commit is contained in:
shoopea 2019-05-15 11:19:34 +08:00
parent 0c285f0c35
commit 87fa993871

1
td.go
View File

@ -58,7 +58,6 @@ func ListenCW(c *tdlib.Client) {
receiver := c.AddEventReceiver(&tdlib.UpdateNewMessage{}, eventFilter, 100) receiver := c.AddEventReceiver(&tdlib.UpdateNewMessage{}, eventFilter, 100)
for newMsg := range receiver.Chan { for newMsg := range receiver.Chan {
updateMsg := (newMsg).(*tdlib.UpdateNewMessage) updateMsg := (newMsg).(*tdlib.UpdateNewMessage)
senderUserID := updateMsg.Message.SenderUserID
if updateMsg.Message.Content.GetMessageContentEnum() == tdlib.MessageTextType { if updateMsg.Message.Content.GetMessageContentEnum() == tdlib.MessageTextType {
txt := updateMsg.Message.Content.(*tdlib.MessageText).Text.Text txt := updateMsg.Message.Content.(*tdlib.MessageText).Text.Text
t := time.Now() t := time.Now()