aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar xithrius <[email protected]>2021-02-13 00:25:09 -0800
committerGravatar xithrius <[email protected]>2021-02-13 00:25:09 -0800
commit88b5b32696c876ee0aa5299eb78bb0d775c5b800 (patch)
tree1184baa222e24627644bb98a73eb8b2f37f19628
parentMerge pull request #1416 from python-discord/pypi-command (diff)
Escaping markdown in all fields that are created.
-rw-r--r--bot/exts/info/pypi.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/bot/exts/info/pypi.py b/bot/exts/info/pypi.py
index cf45b068f..73ec31870 100644
--- a/bot/exts/info/pypi.py
+++ b/bot/exts/info/pypi.py
@@ -7,6 +7,7 @@ from discord.ext.commands import Cog, Context, command
from bot.bot import Bot
from bot.constants import Colours, NEGATIVE_REPLIES
+from discord.utils import escape_markdown
URL = "https://pypi.org/pypi/{package}/json"
FIELDS = ("author", "requires_python", "summary", "license")
@@ -53,7 +54,7 @@ class PyPi(Cog):
embed.add_field(
name=field.replace("_", " ").title(),
- value=field_data,
+ value=escape_markdown(field_data),
inline=False,
)