make all test work again locally

This commit is contained in:
2020-04-18 18:13:52 +02:00
parent d9c61d6afd
commit 7d4e24cb5c
3 changed files with 3 additions and 2 deletions

View File

@@ -34,6 +34,8 @@ app.use(express.static(path.join(__dirname, 'frontend')));
app.use(express.static(`${__dirname}/./frontend`));
app.all("/*", function (req, res, next) {
if (/^\/simcompanies\/API\/.*/.test(req.url))
req.url = req.url.substring(13);
if (!/^\/API\/.*/.test(req.url)) {
return res.sendFile(path.join(__dirname, 'frontend', 'index.html'));
} else return next();