diff options
author | 2020-05-10 18:07:17 -0700 | |
---|---|---|
committer | 2020-05-11 12:03:11 -0700 | |
commit | 4248f88a7407b6e9a5d80800a96f8707003634d3 (patch) | |
tree | 3afcb9c819280aa693f866cd9300cdda5dce4a42 | |
parent | Test `is_maybe_token` returns False for missing parts (diff) |
Token remover: fix `is_maybe_token` returning None instead of False
It's annotated as returning a bool and when the split fails it already
returns False. To be consistent, it should always return a bool.
-rw-r--r-- | bot/cogs/token_remover.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/bot/cogs/token_remover.py b/bot/cogs/token_remover.py index e90d5ab8b..543f4c5a7 100644 --- a/bot/cogs/token_remover.py +++ b/bot/cogs/token_remover.py @@ -121,6 +121,8 @@ class TokenRemover(Cog): if cls.is_valid_user_id(user_id) and cls.is_valid_timestamp(creation_timestamp): return True + return False + @staticmethod def is_valid_user_id(b64_content: str) -> bool: """ |