From 7a04471f178fd9b3d1eb1a71de3913b17ee06be9 Mon Sep 17 00:00:00 2001 From: shoopea Date: Wed, 5 Feb 2020 11:54:41 +0800 Subject: [PATCH] test --- td.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/td.go b/td.go index 7944b2c..d9545e0 100644 --- a/td.go +++ b/td.go @@ -296,10 +296,8 @@ func clientMsg(c *tdlib.Client, m TGCommand) { MQCWMsgQueue <- r } case commandCallback: - p := tdlib.CallbackQueryPayloadData{ - Data: m.CallbackData, - } - a, err := c.GetCallbackQueryAnswer(m.FromChatID64, m.FromMsgID64, p) + p := tdlib.NewCallbackQueryPayloadData(m.CallbackData) + a, err := c.GetCallbackQueryAnswer(m.FromChatID64, m.FromMsgID64, p.(tdlib.CallbackQueryPayload)) logOnError(err, "clientMsg : GetCallbackQueryAnswer") b, _ := json.Marshal(a) log.Printf("GetCallbackQueryAnswer :\n%s\n", string(b))