From b34c360f9e75fcde9c7d90379522a0592988f3b3 Mon Sep 17 00:00:00 2001 From: jean Date: Fri, 23 Feb 2024 18:45:49 +0100 Subject: [PATCH] fix: revert 'if (nextCharCode === 58)' stmt to one line --- index.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index 976850d..d88251a 100644 --- a/index.js +++ b/index.js @@ -371,9 +371,8 @@ Router.prototype.findRoute = function findNode (method, path, constraints = {}) if (charCode === 47) break if (charCode === 58) { const nextCharCode = pattern.charCodeAt(j + 1) - if (nextCharCode === 58) { - j++ - } else break + if (nextCharCode === 58) j++ + else break } }