diff options
| author | 2020-05-07 21:27:45 -0700 | |
|---|---|---|
| committer | 2020-06-13 11:21:08 -0700 | |
| commit | 8fcbad9d2ee11916e398ae9f63826a90cdc45608 (patch) | |
| tree | e1e271e74e5c7b687872a2e0c37ca5ce06baae54 /bot/cogs/codeblock/parsing.py | |
| parent | Code block: fix wrong message shown for bad ticks with a valid language (diff) | |
Code block: document the cog
* Add docstrings for modules
* Rephrase some docstrings and comments
* Fix the grammar of some comments
Diffstat (limited to '')
| -rw-r--r-- | bot/cogs/codeblock/parsing.py | 4 | 
1 files changed, 3 insertions, 1 deletions
| diff --git a/bot/cogs/codeblock/parsing.py b/bot/cogs/codeblock/parsing.py index 6fa6811cc..1bdb3b492 100644 --- a/bot/cogs/codeblock/parsing.py +++ b/bot/cogs/codeblock/parsing.py @@ -1,3 +1,5 @@ +"""This module provides functions for parsing Markdown code blocks.""" +  import ast  import logging  import re @@ -63,7 +65,7 @@ def find_code_blocks(message: str) -> Optional[Sequence[CodeBlock]]:      """      Find and return all Markdown code blocks in the `message`. -    Code blocks with 3 or less lines are excluded. +    Code blocks with 3 or fewer lines are excluded.      If the `message` contains at least one code block with valid ticks and a specified language,      return None. This is based on the assumption that if the user managed to get one code block | 
