telebot
telebot copied to clipboard
bot: use Recipient instead of Chat in Leave and Unpin methods
These methods used Chat when they only call the Recipient() from the Recipient interface.
Having Recipient as parameter allows usage of telebot.ChatID(id)
Yeah, the thing is we don't want to expect Sender
to be used in these calls. But the ChatID
argument will be a more useful case anyway, and passing a proper chat recipient will be up to the user then. So I think we'll merge it.
Are there other methods we need to change for consistency?
When I did this change these 3 methods were the only ones I found but it has been a while. If necessary I could go ahead and verify.