From 8e869004ab60c3d08533a04a8914221c79b1228f Mon Sep 17 00:00:00 2001 From: Brian Read Date: Sat, 9 Aug 2025 16:14:30 +0100 Subject: [PATCH] Fix problem with extended block perl --- mojofmt.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mojofmt.py b/mojofmt.py index 6010b86..2114f9b 100755 --- a/mojofmt.py +++ b/mojofmt.py @@ -90,7 +90,9 @@ RAW_CLOSE_RE = re.compile(r"^\s*pre|script|style|textarea)\s*>\s*$", # Extended EP block delimiters (opening/closing on their own lines) OPEN_BLOCK_RE = re.compile(r'^(?P[ \t]*)<%(?P-?)(?![=#])\s*$') -CLOSE_BLOCK_RE = re.compile(r'^(?P[ \t]*)(?P-?)%>\s*$') +CLOSE_BLOCK_RE = re.compile( + r'^(?P[ \t]*)(?P-?)%(?:>| >)\s*$' +) @dataclass