From 6cfee0b20bd9ff927b83d817182b015b5f4b8cb7 Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Thu, 25 May 2017 17:23:39 -0600 Subject: [PATCH] fix redirect matching --- lib/main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/main.js b/lib/main.js index de18e68..46f0ad0 100644 --- a/lib/main.js +++ b/lib/main.js @@ -51,7 +51,7 @@ module.exports.create = function (app, xconfx, apiFactories, apiDeps, errorIfApi function notConfigured(req, res, next) { if (setupDomain !== req.hostname) { console.log('[notConfigured] req.hostname', req.hostname); - if (/\.html\b/.test(req.url)) { + if ('/' === req.url[req.url.length - 1] || /\.html\b/.test(req.url)) { redirectSetup(req.hostname, req, res); return; }