fix error for #23

This commit is contained in:
Milka64 2020-12-13 17:10:14 +01:00
parent 3beea52ed9
commit 91b758faa9

View file

@ -208,7 +208,6 @@ class Mybot(commands.Cog):
@commands.command(help='Gif me') @commands.command(help='Gif me')
async def gif(self, ctx): async def gif(self, ctx):
query = ctx.message.content.replace('!gif ', '') query = ctx.message.content.replace('!gif ', '')
print(query)
api_instance = giphy_client.DefaultApi() api_instance = giphy_client.DefaultApi()
api_key = self.gif_token api_key = self.gif_token
lang = 'fr' lang = 'fr'
@ -540,9 +539,6 @@ def main():
gif_token = "udhL9Rgdme3HpAoFhWVZoYM0l0XwkzLz" gif_token = "udhL9Rgdme3HpAoFhWVZoYM0l0XwkzLz"
bot = commands.Bot( bot = commands.Bot(
command_prefix='!', command_prefix='!',
gl_url=gl_url,
gl_token=gl_token,
gif_token=gif_token
) )
test = False test = False
@ -636,7 +632,14 @@ def main():
joke = bot.get_command('joke') joke = bot.get_command('joke')
await joke.invoke(ctx) await joke.invoke(ctx)
bot.add_cog(Mybot(bot)) bot.add_cog(
Mybot(
bot
gl_url=gl_url,
gl_token=gl_token,
gif_token=gif_token
)
)
bot.run(token) bot.run(token)