Skip to content

Commit

Permalink
False conditionals now evaluate to ''
Browse files Browse the repository at this point in the history
  • Loading branch information
AcerP-py committed Sep 20, 2024
1 parent 9a76162 commit 0f2cecf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/velocity/_backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def _filter_content(cls, image: Image, text: str) -> str:
if image.satisfies(res.group(2)):
text = re_sub(r"(\?\?.*\?\?)", res.group(3).strip(), text)
else:
text = ""
text = re_sub(r"(\?\?.*\?\?)", "", text)

# remove comments, newlines, and superfluous white space
text = re_sub(r">>>.*", "", text)
Expand Down

0 comments on commit 0f2cecf

Please sign in to comment.