Skip to content

Commit

Permalink
Merge pull request #532 from Crozzers/fix-code-friendly-specific-redos
Browse files Browse the repository at this point in the history
Fix #493 persisting when `code-friendly` extra enabled
  • Loading branch information
nicholasserra committed Oct 20, 2023
2 parents 191b660 + 085e8a2 commit 958eea4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGES.md
Expand Up @@ -5,6 +5,7 @@
- [pull #524] Fix angles being escaped in style blocks (issue #523)
- [pull #527] Fix base64 images being corrupted in safe mode (issue #526)
- [pull #529] Add `breaks` extra with ability to hard break on backslashes (issue #525)
- [pull #532] Fix #493 persisting when `code-friendly` extra enabled

## python-markdown2 2.4.10

Expand Down
2 changes: 1 addition & 1 deletion lib/markdown2.py
Expand Up @@ -2334,7 +2334,7 @@ def _do_tg_spoiler(self, text):

_strong_re = re.compile(r"(\*\*|__)(?=\S)(.*\S)\1", re.S)
_em_re = r"(\*|_)(?=\S)(.*?\S)\1"
_code_friendly_strong_re = re.compile(r"\*\*(?=\S)(.+?[*_]*)\*\*", re.S)
_code_friendly_strong_re = re.compile(r"\*\*(?=\S)(.*\S)\*\*", re.S)
_code_friendly_em_re = r"\*(?=\S)(.+?)\*"
def _do_italics_and_bold(self, text):
if self.extras.get('middle-word-em', True) is False:
Expand Down

0 comments on commit 958eea4

Please sign in to comment.