aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bot/exts/utilities/challenges.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/bot/exts/utilities/challenges.py b/bot/exts/utilities/challenges.py
index 1f296390..751ea2a3 100644
--- a/bot/exts/utilities/challenges.py
+++ b/bot/exts/utilities/challenges.py
@@ -275,10 +275,12 @@ class Challenges(commands.Cog):
`.challenge <language> <query>, <difficulty>` - Pulls a random challenge with the query provided,
under that difficulty within the language's scope.
"""
- if language.lower() not in SUPPORTED_LANGUAGES["stable"] + SUPPORTED_LANGUAGES["beta"]:
+
+ language = language.lower()
+ if language not in SUPPORTED_LANGUAGES["stable"] + SUPPORTED_LANGUAGES["beta"]:
raise commands.BadArgument("This is not a recognized language on codewars.com!")
- get_kata_link = f"https://codewars.com/kata/search/{language.lower()}"
+ get_kata_link = f"https://codewars.com/kata/search/{language}"
params = {}
if query is not None: