From cf69aa54dd9177ff4ce66a6dad7ef7f3dc557894 Mon Sep 17 00:00:00 2001 From: "Soren I. Bjornstad" Date: Mon, 20 Sep 2021 12:18:18 -0500 Subject: [PATCH] don't use walrus operator Forgot I was trying to support 3.6+. --- tzk/builders.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tzk/builders.py b/tzk/builders.py index 2171210..776222e 100644 --- a/tzk/builders.py +++ b/tzk/builders.py @@ -476,7 +476,8 @@ def _set_nontext_field(field: str, mappings: Dict[str, str]) -> None: # First check if the field exists and is currently not set to new_text... line_to_change = -1 for idx, line in enumerate(tiddler_lines): - if m := re.match(f"^{field}: (?P.*)", line): + m = re.match(f"^{field}: (?P.*)", line) + if m: if m.group('value') != new_text: line_to_change = idx break