From 47077dbef758d6e0e2d68198d0462c462fdadb78 Mon Sep 17 00:00:00 2001 From: oidocrop <10498-oidocrop@users.noreply.gitgud.io> Date: Sun, 31 Mar 2019 15:16:38 -0700 Subject: [PATCH] fix regex parsing --- src/uncategorized/main.tw | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/uncategorized/main.tw b/src/uncategorized/main.tw index 87d76c8ee01..72938077515 100644 --- a/src/uncategorized/main.tw +++ b/src/uncategorized/main.tw @@ -88,9 +88,10 @@ /* Check if custom rules have an assignation operator */ <<set _RL = $defaultRules.length>> +<<set _regex = /[^=<>]=[^=<>]/gi>> <<set $rulesError = false>> <<for _itr = 0; _itr < _RL; _itr++>> - <<if $defaultRules[_itr].condition.function == "custom" && $defaultRules[_itr].condition.data.match(/[^=<>]=[^=<>]/gi)>> + <<if $defaultRules[_itr].condition.function == "custom" && $defaultRules[_itr].condition.data.match(_regex)>> <<set $rulesError = true>> <<break>> <</if>> -- GitLab