aboutsummaryrefslogtreecommitdiffstats
path: root/bot/exts/evergreen/pythonfacts.py
diff options
context:
space:
mode:
authorGravatar ToxicKidz <[email protected]>2021-05-04 12:57:03 -0400
committerGravatar ToxicKidz <[email protected]>2021-05-04 12:57:03 -0400
commita6cc40ff3b323dff112d7f8c339e124f3a6d9980 (patch)
treef0cdec46d302cfc629fe9277df5cfbe6251a861b /bot/exts/evergreen/pythonfacts.py
parentchore: Don't return a Message object when the return annotation is None (diff)
chore: Prefer double quotes over single quotes
Diffstat (limited to 'bot/exts/evergreen/pythonfacts.py')
-rw-r--r--bot/exts/evergreen/pythonfacts.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/bot/exts/evergreen/pythonfacts.py b/bot/exts/evergreen/pythonfacts.py
index 73234d55..2dc4996f 100644
--- a/bot/exts/evergreen/pythonfacts.py
+++ b/bot/exts/evergreen/pythonfacts.py
@@ -6,7 +6,7 @@ from discord.ext import commands
from bot.bot import Bot
from bot.constants import Colours
-with open('bot/resources/evergreen/python_facts.txt') as file:
+with open("bot/resources/evergreen/python_facts.txt") as file:
FACTS = itertools.cycle(list(file))
COLORS = itertools.cycle([Colours.python_blue, Colours.python_yellow])
@@ -15,13 +15,13 @@ COLORS = itertools.cycle([Colours.python_blue, Colours.python_yellow])
class PythonFacts(commands.Cog):
"""Sends a random fun fact about Python."""
- @commands.command(name='pythonfact', aliases=['pyfact'])
+ @commands.command(name="pythonfact", aliases=["pyfact"])
async def get_python_fact(self, ctx: commands.Context) -> None:
"""Sends a Random fun fact about Python."""
- embed = discord.Embed(title='Python Facts',
+ embed = discord.Embed(title="Python Facts",
description=next(FACTS),
colour=next(COLORS))
- embed.add_field(name='Suggestions',
+ embed.add_field(name="Suggestions",
value="Suggest more facts [here!](https://github.com/python-discord/meta/discussions/93)")
await ctx.send(embed=embed)