Skip to content

Commit

Permalink
OF: useless placement of assert
Browse files Browse the repository at this point in the history
The assert needs to be before the variable is first used
  • Loading branch information
sebbASF committed Jun 29, 2023
1 parent 4b6ee66 commit 4cf1d16
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/asfreader.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,9 @@ def read(self, source_path):
# prepare text as an ezt template
# compress_whitespace=0 is required as blank lines and indentation have meaning in markdown.
template = ezt.Template(compress_whitespace=0)
assert template
reader = ASFTemplateReader(source_path, text)
template.parse(reader, base_format=ezt.FORMAT_HTML)
assert template
# generate content from ezt template with metadata
fp = io.StringIO()
template.generate(fp, metadata)
Expand Down

0 comments on commit 4cf1d16

Please sign in to comment.