[ChatChart] Round "others" output

This commit is contained in:
aikaterna
2021-10-04 08:03:32 -07:00
committed by GitHub
parent 6871ec09ae
commit b80dda4688

View File

@@ -83,7 +83,7 @@ class Chatchart(commands.Cog):
labels = ["{} {:g}%".format(x[0], round(x[1], 1)) for x in top]
if len(top) >= 20:
sizes = sizes + [others]
labels = labels + ["Others {:g}%".format(others)]
labels = labels + ["Others {:g}%".format(round(others, 1))]
if len(channel_or_guild.name) >= 19:
if isinstance(channel_or_guild, discord.Guild):
channel_or_guild_name = "{}...".format(channel_or_guild.name[:19])