settings-site: phase 3 stack hygiene (express 5, drop node-fetch, engines, nvmrc)
This commit is contained in:
@@ -6,7 +6,6 @@ const helmet = require('helmet');
|
||||
const rateLimit = require('express-rate-limit');
|
||||
const { doubleCsrf } = require('csrf-csrf');
|
||||
const path = require('path');
|
||||
const fetch = require('node-fetch');
|
||||
|
||||
const app = express();
|
||||
const PORT = parseInt(process.env.SETTINGS_PORT) || 12752;
|
||||
@@ -184,7 +183,7 @@ app.get('/api/discord/guild', apiLimiter, requireAuth, proxy('GET', '/discord/gu
|
||||
app.post('/api/restart', apiLimiter, requireAuth, proxy('POST', '/restart'));
|
||||
app.get('/api/restart/status', apiLimiter, requireAuth, proxy('GET', '/restart/status'));
|
||||
|
||||
app.get('*', requireAuth, (req, res) => {
|
||||
app.get('/*splat', requireAuth, (req, res) => {
|
||||
res.sendFile(path.join(__dirname, 'public', 'index.html'));
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user