From eaae8a7ecee02b90e204595d699a59c6d55bdf40 Mon Sep 17 00:00:00 2001 From: Abigail Gold Date: Sat, 9 Nov 2019 23:01:58 -0500 Subject: [PATCH] ternary statements, ofc --- cogs/basecog.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/cogs/basecog.py b/cogs/basecog.py index f112612..a03b538 100644 --- a/cogs/basecog.py +++ b/cogs/basecog.py @@ -39,9 +39,7 @@ class BaseCog(commands.Cog): @commands.command(name="ping") async def _ping(self, ctx: commands.Context): """Show the current latency to the discord endpoint.""" - content = '' - if random.random() < 0.05: - content = f'<@{ctx.message.author.id}>' + content = ctx.message.author.mention if random.random() < 0.05 else '' embed = discord.Embed(title="**Pong!**", description=f'Current ping is {self.bot.latency*1000:.1f} ms', colour=self.gs.colours.neutral,