From 45a63a849358a1b392112a52ea4e04ae7558a92a Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 17 Feb 2025 07:44:19 +0100 Subject: Merging upstream version 2.1.2~dev0+20240910. Signed-off-by: Daniel Baumann --- gen_web_gettext.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gen_web_gettext.py') diff --git a/gen_web_gettext.py b/gen_web_gettext.py index 80186e9..37ffba7 100755 --- a/gen_web_gettext.py +++ b/gen_web_gettext.py @@ -60,7 +60,7 @@ def check_missing_markup(js_dir): # Ignore string that contains only digits or specificied strings in skip. if ( not string - or string.split('\'')[1].isdigit() + or string.split("'")[1].isdigit() or any(x in string for x in skip) ): continue @@ -82,7 +82,7 @@ GETTEXT_SUBST_TPL = "GetText.add('{key}','${{escape(_(\"{key}\"))}}')\n" def create_gettext_js(js_dir): - string_re = re.compile('_\\(\'(.*?)\'\\)') + string_re = re.compile("_\\('(.*?)'\\)") strings = {} for root, dnames, files in os.walk(js_dir): for filename in files: -- cgit v1.2.3