From b77ccadcbab379cc77065c323b6af7815bbca037 Mon Sep 17 00:00:00 2001 From: Debanjum Singh Solanky Date: Fri, 17 Jun 2022 05:03:57 +0300 Subject: [PATCH] Make property key regex more strict. Property key has to be alphanumeric --- src/processor/org_mode/orgnode.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/processor/org_mode/orgnode.py b/src/processor/org_mode/orgnode.py index 50d1f181..3b6973bc 100644 --- a/src/processor/org_mode/orgnode.py +++ b/src/processor/org_mode/orgnode.py @@ -110,7 +110,7 @@ def makelist(filename): if not in_properties_drawer and line[:1] != '#': bodytext = bodytext + line - prop_srch = re.search(r'^\s*:(.*?):\s*(.*?)\s*$', line) + prop_srch = re.search(r'^\s*:([a-zA-Z0-9]+):\s*(.*?)\s*$', line) if prop_srch: # Set ID property to an id based org-mode link to the entry if prop_srch.group(1) == 'ID':