This commit is contained in:
shoopea 2021-11-11 23:22:30 +08:00
parent 4308dcf9f9
commit 83ccdf35df

View File

@ -729,6 +729,9 @@ func ListenAll(c *tdlib.Client) {
func ForwardMsg(c *tdlib.Client, msgID int64, fromChatID int64, toChatID int64) int64 { func ForwardMsg(c *tdlib.Client, msgID int64, fromChatID int64, toChatID int64) int64 {
msgIDs := make([]int64, 1) msgIDs := make([]int64, 1)
msgIDs[0] = msgID msgIDs[0] = msgID
fmt.Printf("ForwardMsg fromChatID : %d\n", fromChatID)
fmt.Printf("ForwardMsg toChatID : %d\n", toChatID)
fmt.Printf("ForwardMsg msgID : %d\n", msgID)
msgs, err := c.ForwardMessages(toChatID, fromChatID, msgIDs, false, false, false) msgs, err := c.ForwardMessages(toChatID, fromChatID, msgIDs, false, false, false)
if err != nil { if err != nil {
fmt.Printf("ForwardMsg (error) : %s\n", err.Error()) fmt.Printf("ForwardMsg (error) : %s\n", err.Error())