mirror of
https://gitlab.com/MrFry/mrfrys-node-server
synced 2025-04-01 20:24:18 +02:00
Db structure changes
This commit is contained in:
parent
6eef9fd1c0
commit
bf2f63e810
6 changed files with 19 additions and 93 deletions
|
@ -54,7 +54,7 @@ function GetApp(): ModuleType {
|
|||
auth({
|
||||
userDB: userDB,
|
||||
jsonResponse: false,
|
||||
exceptions: ['/favicon.ico', '/getVeteranPw'],
|
||||
exceptions: ['/favicon.ico'],
|
||||
})
|
||||
)
|
||||
app.use((req: Request, res, next) => {
|
||||
|
@ -90,7 +90,7 @@ function GetApp(): ModuleType {
|
|||
|
||||
routes.forEach((route) => {
|
||||
logger.DebugLog(`Added route /${route}`, 'DataEditor routes', 1)
|
||||
app.get(`/${route}`, function(req: Request, res) {
|
||||
app.get(`/${route}`, function (req: Request, res) {
|
||||
res.redirect(`${route}.html`)
|
||||
})
|
||||
})
|
||||
|
@ -99,16 +99,16 @@ function GetApp(): ModuleType {
|
|||
|
||||
// --------------------------------------------------------------
|
||||
|
||||
app.get('/', function(req: Request, res) {
|
||||
app.get('/', function (req: Request, res) {
|
||||
res.end('hai')
|
||||
logger.LogReq(req)
|
||||
})
|
||||
|
||||
app.get('*', function(req: Request, res) {
|
||||
app.get('*', function (req: Request, res) {
|
||||
res.status(404).render('404')
|
||||
})
|
||||
|
||||
app.post('*', function(req: Request, res) {
|
||||
app.post('*', function (req: Request, res) {
|
||||
res.status(404).render('404')
|
||||
})
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue