This commit is contained in:
shoopea 2019-06-09 00:57:04 +08:00
parent 968d7ae958
commit 9cbeb18a84

View File

@ -265,7 +265,7 @@ func TGCmdWorker(id int, b *tb.Bot, cmds <-chan TGCommand) {
ID: int(c.FromMsgID64),
Chat: &ch,
}
_, err := c.Document.Send(b, &m)
_, err := c.Document.Send(b, &m, nil)
logOnError(err, "TGCmdWorker["+strconv.Itoa(id)+"] : ReplyDocument")
case commandSendMsg:
if c.ToChatID64 != 0 {
@ -283,10 +283,10 @@ func TGCmdWorker(id int, b *tb.Bot, cmds <-chan TGCommand) {
}
case commandSendDocument:
if c.ToChatID64 != 0 {
_, err := c.Document.Send(b, c.ToChatID64)
_, err := c.Document.Send(b, c.ToChatID64, nil)
logOnError(err, "TGCmdWorker["+strconv.Itoa(id)+"] : SendDocument Chat")
} else if c.ToUserID64 != 0 {
_, err := c.Document.Send(b, c.ToUserID64)
_, err := c.Document.Send(b, c.ToUserID64, nil)
logOnError(err, "TGCmdWorker["+strconv.Itoa(id)+"] : SendDocument Chat")
}
default: