Working on the config file

It's kind of working? Well, the program crashes due to a promise failure.
This commit is contained in:
2021-02-04 13:42:53 +00:00
parent e5a81c79e1
commit dafcd3b833
5 changed files with 54 additions and 132 deletions
+2 -2
View File
@@ -26,11 +26,11 @@ app.use('/api/accounts', require('./accounts'));
app.use('/api/admin', require('./admin'));
//send static files
app.use('/', express.static(path.resolve(__dirname, 'public')));
app.use('/', express.static(path.resolve(__dirname, '..', 'public')));
//fallback to the index file
app.get('*', (req, res) => {
res.sendFile(path.resolve(__dirname, 'public' , 'index.html'));
res.sendFile(path.resolve(__dirname, '..', 'public' , 'index.html'));
});
//startup