Skip to content

Commit

Permalink
fix: lint error addressed
Browse files Browse the repository at this point in the history
  • Loading branch information
camalot committed Nov 21, 2023
1 parent 3065124 commit 28722b7
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
12 changes: 8 additions & 4 deletions bot/cogs/channel.py
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@ async def mute(self, ctx, userOrRole: typing.Optional[typing.Union[discord.Role,
)

except Exception as ex:
self.log.error(guild_id, _method , str(ex), traceback.format_exc())
self.log.error(guild_id, _method, str(ex), traceback.format_exc())
await self._messaging.notify_of_error(ctx)

@channel.command()
Expand Down Expand Up @@ -474,7 +474,7 @@ async def unmute(self, ctx, userOrRole: typing.Optional[typing.Union[discord.Rol
)

except Exception as ex:
self.log.error(guild_id, _method , str(ex), traceback.format_exc())
self.log.error(guild_id, _method, str(ex), traceback.format_exc())
await self._messaging.notify_of_error(ctx)

@channel.command()
Expand Down Expand Up @@ -524,7 +524,7 @@ async def owner(self, ctx, member: discord.Member):
delete_after=5,
)
except Exception as ex:
self.log.error(guild_id, _method , str(ex), traceback.format_exc())
self.log.error(guild_id, _method, str(ex), traceback.format_exc())
await self._messaging.notify_of_error(ctx)

@channel.command()
Expand Down Expand Up @@ -557,7 +557,11 @@ async def game(self, ctx):
return
owner = await self._users.get_or_fetch_member(ctx.guild, owner_id)
if owner:
selected_title = await self.ask_game_for_user(targetChannel=ctx.channel, user=owner, title=self.settings.get_string(guild_id, "title_update_to_game"))
selected_title = await self.ask_game_for_user(
targetChannel=ctx.channel,
user=owner,
title=self.settings.get_string(guild_id, "title_update_to_game")
)
if selected_title:
await self._name(ctx, selected_title, False)
else:
Expand Down
6 changes: 3 additions & 3 deletions bot/cogs/game_name.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ async def auto(self, ctx):
await ctx.message.delete()

except Exception as ex:
self.log.error(guild_id, _method , str(ex), traceback.format_exc())
self.log.error(guild_id, _method, str(ex), traceback.format_exc())
await self.messaging_helper.notify_of_error(ctx)

@game.command(name="name", aliases=["n"])
Expand All @@ -65,7 +65,7 @@ async def name(self, ctx):
await ctx.message.delete()

except Exception as ex:
self.log.error(guild_id, _method , str(ex), traceback.format_exc())
self.log.error(guild_id, _method, str(ex), traceback.format_exc())
await self.messaging_helper.notify_of_error(ctx)

@commands.Cog.listener()
Expand Down Expand Up @@ -183,7 +183,7 @@ async def select_callback(view: discord.ui.View, interaction: discord.Interactio
except discord.errors.NotFound as nf:
self.log.warn(guild_id, _method, str(nf), traceback.format_exc())
except Exception as ex:
self.log.error(guild_id, _method , str(ex), traceback.format_exc())
self.log.error(guild_id, _method, str(ex), traceback.format_exc())


async def setup(bot):
Expand Down

0 comments on commit 28722b7

Please sign in to comment.