celestix / gotgproto

A wrapper for Go Telegram Client, i.e. gotd/td.
GNU General Public License v3.0
160 stars 31 forks source link

Fix bug in retrieving replyTo messages and added flag to retrieve entire reply chain #37

Closed jimpo26 closed 6 months ago

jimpo26 commented 6 months ago

In the dispatcher/dispatcher.go file, we can't start a goroutine because in that case the resulting update object will return BEFORE the replied message got fetched, so I called the method handleUpdateRepliedToMessage synchronously. while I was working on it, I also added a new flag to options type (FetchEntireReplyChain) to fetch the entire message reply chain instead of only the last replied message

celestix commented 6 months ago

Good catch, Thank you for the PR!