Skip to content

Commit

Permalink
Run black and fix some wording
Browse files Browse the repository at this point in the history
  • Loading branch information
PredaaA committed Aug 9, 2023
1 parent 79dcb1e commit 63a0ba5
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions redbot/core/core_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -3233,18 +3233,14 @@ async def _set_status_custom(self, ctx: commands.Context, *, name: str = None):
status = ctx.bot.guilds[0].me.status if len(ctx.bot.guilds) > 0 else discord.Status.online
if name:
if len(name) > 128:
await ctx.send(
_("The maximum length of custom descriptions is 128 characters.")
)
await ctx.send(_("The maximum length of custom statuses is 128 characters."))
return
activity = discord.Activity(name=name, state=name, type=discord.ActivityType.custom)
else:
activity = None
await ctx.bot.change_presence(status=status, activity=activity)
if activity:
await ctx.send(
_("Status set to `{name}`.").format(name=name)
)
await ctx.send(_("Custom status set to `{name}`.").format(name=name))
else:
await ctx.send(_("Custom status cleared."))

Expand Down

0 comments on commit 63a0ba5

Please sign in to comment.