-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Add both handlers for queries from new Payment API #630
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
jh0ker
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks very good on a first glance, just two minor comments for now
telegram/precheckoutquery.py
Outdated
| return data | ||
|
|
||
| def answer(self, *args, **kwargs): | ||
| """Shortcut for ``bot.answerPreCheckoutQuery(update.callback_query.id, *args, **kwargs)``""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The docstring has callback_query instead of pre_checkout_query
telegram/shippingquery.py
Outdated
| return data | ||
|
|
||
| def answer(self, *args, **kwargs): | ||
| """Shortcut for ``bot.answerShippingQuery(update.callback_query.id, *args, **kwargs)``""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same as above
telegram/update.py
Outdated
| user = self.shipping_query.from_user | ||
|
|
||
| elif self.pre_checkout_query: | ||
| user = self.pre_checkout_query |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing a .user here?
|
Thanks :) Can you open the PR again, to the master branch? |
Added PreCheckoutQueryHandler and ShippingQueryHandler