diff --git a/src/main.py b/src/main.py index 2069206..ab5a5e7 100644 --- a/src/main.py +++ b/src/main.py @@ -12,13 +12,13 @@ customPrefix = keys["PREFIX"] client = commands.Bot(command_prefix = customPrefix, case_insensitive = True, intents = discord.Intents.all()) slash = SlashCommand(client, sync_commands = True) -if keys["DEACTIVATION"] != "None": +if keys["DEACTIVATE"] != "None": path = getcwd() - for file in keys["DEACTIVATION"]: + for file in keys["DEACTIVATE"]: try: rename(f"{path}/cogs/{file}.py", f"{path}/cogs/-{file}.py") # désactivation except: - print(f"\nNo file {file} found, check your \"DEACTIVATION\" variable.") + print(f"\nNo file {file} found, check your \"DEACTIVATE\" variable.") exit(1) for file in listdir("cogs"): diff --git a/src/utils/core.py b/src/utils/core.py index 56e8098..7000f9f 100644 --- a/src/utils/core.py +++ b/src/utils/core.py @@ -172,11 +172,11 @@ def load(variables): for var in variables: try: res = environ[var] - if var == "DEACTIVATION": + if var == "DEACTIVATE": res = list(set(res.split(',')) - {""}) # create a list for the cogs we need to deactivate and remove blank channels and doubles keys[var] = res except KeyError: - if var == "DEACTIVATION": + if var == "DEACTIVATE": keys[var] = "None" else: print(f"Please set the environment variable {var} (.env file supported)")