-
Notifications
You must be signed in to change notification settings - Fork 60
Open
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomersupstreamThis requires action with dependenciesThis requires action with dependencies
Description
Line 9 in 5d892a2
| @dp.message_handler(commands=["set_superuser"], commands_prefix="!", is_superuser=True) |
In the first lines of the function above, you check the user_id is existed by calling get_args method of the message. The check always returns false.
The method message.get_args() returns an argument only if it command that starts with /.
Trace:
message.get_args() -> message.get_full_command() -> message.is_command() -> return self.text and self.text.startswith("/")
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomersupstreamThis requires action with dependenciesThis requires action with dependencies