diff --git a/__pycache__/perso_commands.cpython-312.pyc b/__pycache__/perso_commands.cpython-312.pyc index 3f74df3..94679f8 100644 Binary files a/__pycache__/perso_commands.cpython-312.pyc and b/__pycache__/perso_commands.cpython-312.pyc differ diff --git a/perso_commands.py b/perso_commands.py index c2d6776..12520fe 100644 --- a/perso_commands.py +++ b/perso_commands.py @@ -7,15 +7,15 @@ import io _sql_table="""CREATE TABLE personnages ( - nom_court varchar(255), - nom_complet text, - image text, - histoire text, - pouvoirs text, - uuid TEXT, - age INTEGER, - sexe TEXT, - guild_id INTEGER NULL + nom_court varchar(255), + nom_complet text, + image text, + histoire text, + pouvoirs text, + uuid TEXT, + age INTEGER, + sexe TEXT, + guild_id INTEGER NULL )""" async def setup(bot:GammaRPBot): @@ -81,7 +81,7 @@ class PersoCommands(app_commands.Group): embed = await perso_embed(self.bot,row) await interaction.response.send_message(f"Affichage de {row["nom_complet"]}({row["nom_court"]})",embed=embed) @show_character.autocomplete(name="short_name") - async def autocomplete_short_name(self,interaction:discord.Interaction): + async def autocomplete_short_name(self,interaction:discord.Interaction,current:str): res = await self.bot.db.execute("SELECT nom_court FROM personnages WHERE uuid=? AND (guild_id=? OR guild_id IS NULL)",(interaction.user.id,interaction.guild.id)) rows = await res.fetchall() await res.close()