Replies: 1 comment
-
You need to return either telebot.handler_backends.CancelUpdate or telebot.handler_backends.SkipHandler Returning SkipHandler will skip the handler execution and will call your post_process middleware function. Here's the example of using CancelUpdate: |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I want to use a middleware to incorporate custom service logic into my bot, that requires it to stop processing a command if certain conditions are met.
How do I explicitly stop every message_handler decorator from processing a command if various conditions are met inside the middleware?
Beta Was this translation helpful? Give feedback.
All reactions