Skip to content

Commit

Permalink
Merge pull request #1342 from gotd/fix/set-reply-to
Browse files Browse the repository at this point in the history
fix(upconv): properly convert ReplyTo
  • Loading branch information
ernado committed Mar 24, 2024
2 parents 268edb3 + ac4e085 commit 286f115
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions telegram/internal/upconv/upconv.go
Expand Up @@ -22,6 +22,13 @@ func convertOptional(msg *tg.Message, i tg.UpdatesClass) {
msg.SetReplyTo(&v)
}
}
if u, ok := i.(interface {
GetReplyTo() (tg.MessageReplyHeaderClass, bool)
}); ok {
if v, ok := u.GetReplyTo(); ok {
msg.SetReplyTo(v)
}
}
if u, ok := i.(interface {
GetEntities() ([]tg.MessageEntityClass, bool)
}); ok {
Expand Down

0 comments on commit 286f115

Please sign in to comment.