hot fixed all the bugs introduced

This commit is contained in:
2023-06-09 16:59:27 +02:00
parent 489792a264
commit e2d49cf1f3
5 changed files with 14 additions and 6 deletions
+3
View File
@@ -31,6 +31,7 @@ class SlashStats(commands.Cog):
async with aiohttp.ClientSession() as session:
players = await get_all_playerids(session, playernames)
players = players[0]
if(players == {} or players.keys() == []):
await interaction.response.send_message("```No existing player given.\nIf you put in multiple players make sure to split them with a comma(,)```")
return
@@ -43,6 +44,7 @@ class SlashStats(commands.Cog):
async with aiohttp.ClientSession() as session:
botmessage, img_file = await get_allplayer_stats(session, players.values(), weaponid, weaponname, server)
if(img_file != ""):
await interaction.response.send_message(file=img_file, embed=botmessage)
else:
@@ -71,6 +73,7 @@ class SlashStats(commands.Cog):
return data
async def setup(client):
await client.add_cog(SlashStats(client))