[mod-help] Fix des oublis
This commit is contained in:
parent
08d9998f73
commit
4c5820b19e
@ -33,9 +33,6 @@ class BaseClass:
|
||||
"authorized_users": [], "command_text": self.name.lower()})
|
||||
|
||||
async def send_help(self, channel):
|
||||
if not self.config.help_active:
|
||||
return
|
||||
|
||||
embed = discord.Embed(
|
||||
title="[{nom}] - Aide".format(nom=self.name),
|
||||
description="*" + self.help["description"].format(prefix=self.client.config['prefix']) + "*",
|
||||
|
@ -17,7 +17,7 @@ class MainClass(BaseClassPython):
|
||||
async def com_list(self, message, args, kwargs):
|
||||
embed = discord.Embed(title="[Aide] - Liste des modules", color=self.config.color)
|
||||
for moduleName in list(self.client.modules.keys()):
|
||||
if self.client.modules[moduleName]["initialized_class"].help_active:
|
||||
if self.client.modules[moduleName]["initialized_class"].config.help_active:
|
||||
embed.add_field(
|
||||
name=moduleName.capitalize(),
|
||||
value=self.client.modules[moduleName]["initialized_class"].help["description"])
|
||||
@ -28,7 +28,8 @@ class MainClass(BaseClassPython):
|
||||
# await module["initialized_class"].send_help(message.channel)
|
||||
|
||||
async def command(self, message, args, kwargs):
|
||||
if len(args) and args[0] in self.client.modules.keys():
|
||||
if len(args) and args[0] in self.client.modules.keys() and self.client.modules[args[0]][
|
||||
"initialized_class"].config.help_active:
|
||||
await self.client.modules[args[0]]["initialized_class"].send_help(message.channel)
|
||||
else :
|
||||
await self.send_help(message.channel)
|
Loading…
Reference in New Issue
Block a user