From 0b9c4ececa4fc008e431f5c89da049a3bbe04bb4 Mon Sep 17 00:00:00 2001 From: "Nyeki.py" <84998222+Nekidev@users.noreply.github.com> Date: Sat, 19 Oct 2024 01:56:58 -0300 Subject: [PATCH] fix(bot): :bug: Discord user converter not working. --- payphone/core/converters.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/payphone/core/converters.py b/payphone/core/converters.py index cf73d5d..cf18bac 100644 --- a/payphone/core/converters.py +++ b/payphone/core/converters.py @@ -44,11 +44,11 @@ class DiscordUserID(converter.Converter): """Converts a URL, ID, or reply into a Discord User ID.""" async def convert(self, ctx: commands.Context, argument: str) -> int: - if len(argument) > 17 and argument[2:-1].isdecimal(): - return int() - if argument.isdecimal() and len(argument) in range(17, 20): return int(argument) + + if len(argument) > 17 and argument[2:-1].isdecimal(): + return int(argument) if argument.startswith("https://discord.com/users/") or argument.startswith( "discord://-/users/"