Skip to content

Commit c9e8709

Browse files
committed
Fix some ESLint issues
1 parent 9f3a446 commit c9e8709

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/validateResourcePath.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ module.exports = function (config, req, res, decodedToken, productOnly, logger,
7373
regExPatternStr = regExPatternStr.replace('*', '\\w+');
7474
placeholder = new RegExp(placeholder, "g");
7575

76-
regExPatternStr = regExPatternStr.replace(placeholder, '\.*');
76+
regExPatternStr = regExPatternStr.replace(placeholder, '.*');
7777

7878
try {
7979
var proxyRegEx = new RegExp(`^${regExPatternStr}$`, 'ig');
@@ -93,9 +93,10 @@ module.exports = function (config, req, res, decodedToken, productOnly, logger,
9393
debug("matches proxy rules: " + matchesProxyRules);
9494

9595
//add pattern matching here
96-
if (!productOnly)
96+
if (!productOnly) {
9797
return matchesProxyRules && validProxyNames.indexOf(proxy.name) >= 0;
98-
else
98+
} else {
9999
return matchesProxyRules;
100+
}
100101
});
101102
}

0 commit comments

Comments
 (0)