diff options
| author | 2020-05-03 20:44:15 -0700 | |
|---|---|---|
| committer | 2020-06-13 11:21:04 -0700 | |
| commit | b914d236b8129ae2616424629922db81a79eeead (patch) | |
| tree | d4958b3855c9a038b040995ed9ed688f422fa486 | |
| parent | Code block: use a more efficient line count check (diff) | |
Code block: fix code block language regex
It was missing a quantifier to match more than 1 character.
| -rw-r--r-- | bot/cogs/codeblock/cog.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bot/cogs/codeblock/cog.py b/bot/cogs/codeblock/cog.py index 6699abd2f..cde16bd9f 100644 --- a/bot/cogs/codeblock/cog.py +++ b/bot/cogs/codeblock/cog.py @@ -15,7 +15,7 @@ from bot.utils.messages import wait_for_deletion log = logging.getLogger(__name__) RE_MARKDOWN = re.compile(r'([*_~`|>])') -RE_CODE_BLOCK_LANGUAGE = re.compile(r"```(?:[^\W_])\n(.*?)```", re.DOTALL) +RE_CODE_BLOCK_LANGUAGE = re.compile(r"```(?:[^\W_]+)\n(.*?)```", re.DOTALL) INVALID_BACKTICKS = { "'''", '"""', |