From 1a1d09862a54df2e31ea3388c1dcbfab5c17ddde Mon Sep 17 00:00:00 2001 From: mike12345567 Date: Tue, 22 Sep 2020 08:58:16 +0100 Subject: [PATCH] Simplifying review comment changes. --- packages/server/src/workflows/thread.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/server/src/workflows/thread.js b/packages/server/src/workflows/thread.js index 1b83a05a3..ab494e327 100644 --- a/packages/server/src/workflows/thread.js +++ b/packages/server/src/workflows/thread.js @@ -10,8 +10,7 @@ function cleanMustache(string) { "]": "", } let regex = new RegExp(/{{[^}}]*}}/g) - let matches = [...string.matchAll(regex)] - for (let match of matches) { + for (let match of string.matchAll(regex)) { let baseIdx = string.indexOf(match) for (let key of Object.keys(charToReplace)) { let idxChar = match[0].indexOf(key)