From e584c13e8d7e78ac469db1ca034197d77815b4cf Mon Sep 17 00:00:00 2001 From: Athanasius Date: Sun, 13 Jun 2021 15:20:41 +0100 Subject: [PATCH] l10n script: remove extraneous "and not out" from conditionals Left over from when trying to fix the old loop. --- scripts/find_localised_strings.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/find_localised_strings.py b/scripts/find_localised_strings.py index 0e8d2e0b..ff5dc693 100644 --- a/scripts/find_localised_strings.py +++ b/scripts/find_localised_strings.py @@ -88,7 +88,7 @@ def extract_comments(call: ast.Call, lines: list[str], file: pathlib.Path) -> Op match = COMMENT_OWN_LINE_RE.match(above_line) if match: above_comment = match.group(1).strip() - if not above_comment.startswith('# LANG:') and not out: + if not above_comment.startswith('# LANG:'): bad_comment = f'Unknown comment for {file}:{call.lineno} {above_line}' above_comment = None @@ -99,7 +99,7 @@ def extract_comments(call: ast.Call, lines: list[str], file: pathlib.Path) -> Op match = COMMENT_SAME_LINE_RE.match(current_line) if match: current_comment = match.group(1).strip() - if not current_comment.startswith('# LANG:') and not out: + if not current_comment.startswith('# LANG:'): bad_comment = f'Unknown comment for {file}:{call.lineno} {current_line}' current_comment = None