aboutsummaryrefslogtreecommitdiffstats
path: root/bot
diff options
context:
space:
mode:
authorGravatar brad90four <[email protected]>2021-10-28 09:01:57 -0400
committerGravatar brad90four <[email protected]>2021-10-28 09:01:57 -0400
commitb2151ebc86a538b6e8eb492a2b10a7cd2c12f900 (patch)
tree0c9624c32ac97360325b2f6deff19faee8da000d /bot
parentchore: change to tuples, various suggested changes (diff)
chore: correct capitalization of command name in embed
Diffstat (limited to 'bot')
-rw-r--r--bot/exts/utilities/color.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/bot/exts/utilities/color.py b/bot/exts/utilities/color.py
index e9e8dcf6..573039fa 100644
--- a/bot/exts/utilities/color.py
+++ b/bot/exts/utilities/color.py
@@ -28,9 +28,14 @@ class Colour(commands.Cog):
r, g, b = rgb
name = self._rgb_to_name(rgb)
colour_mode = ctx.invoked_with
- desc = f"{colour_mode.upper()} information for `{name or 'the input colour'}`."
+ colour_or_color = ctx.command.name
+ if colour_mode not in ("name", "hex", "random"):
+ colour_mode = colour_mode.upper()
+ else:
+ colour_mode = colour_mode.title()
+ desc = f"{colour_mode} information for `{name or 'the input colour'}`."
colour_embed = Embed(
- title="Colour",
+ title=colour_or_color.title(),
description=desc,
colour=int(f"{r:02x}{g:02x}{b:02x}", 16)
)