Set origin id, if available, to replies bridged from Telegram
This commit is contained in:
parent
945b9c063b
commit
79fc0ddbe5
|
@ -330,9 +330,13 @@ func (c *Client) getMessageReply(message *client.Message) (reply *gateway.Reply,
|
|||
return
|
||||
}
|
||||
|
||||
replyId, err := gateway.IdsDB.GetByTgIds(c.Session.Login, c.jid, message.ChatId, message.ReplyToMessageId)
|
||||
if err != nil {
|
||||
replyId = strconv.FormatInt(message.ReplyToMessageId, 10)
|
||||
}
|
||||
reply = &gateway.Reply{
|
||||
Author: fmt.Sprintf("%v@%s", c.getSenderId(replyMsg), gateway.Jid.Full()),
|
||||
Id: strconv.FormatInt(message.ReplyToMessageId, 10),
|
||||
Id: replyId,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue