More minor updates to fix things
parent
4eb3be36e1
commit
f178d3edd8
2
app.js
2
app.js
|
@ -1,7 +1,7 @@
|
|||
#!/usr/bin/env node
|
||||
/* eslint unicorn/no-process-exit: 0 */
|
||||
|
||||
const config = require('./application/config')
|
||||
const config = require('./application/config.js')
|
||||
|
||||
// Until node 11 adds flatmap, we use this:
|
||||
require('array.prototype.flatmap').shim()
|
||||
|
|
|
@ -14,11 +14,11 @@ const sanitizeAddress = param('address').customSanitizer(
|
|||
router.get('^/:address([^@/]+@[^@/]+)', sanitizeAddress, (req, res, _next) => {
|
||||
const mailProcessingService = req.app.get('mailProcessingService')
|
||||
res.render('inbox', {
|
||||
title: `${config.branding[0]} | ` + req.params.address,
|
||||
title: `${config.http.branding[0]} | ` + req.params.address,
|
||||
address: req.params.address,
|
||||
mailSummaries: mailProcessingService.getMailSummaries(req.params.address),
|
||||
madeby: config.branding[1],
|
||||
madebysite: config.branding[2]
|
||||
madeby: config.http.branding[1],
|
||||
madebysite: config.http.branding[2]
|
||||
})
|
||||
})
|
||||
|
||||
|
@ -40,8 +40,8 @@ router.get(
|
|||
address: req.params.address,
|
||||
mail,
|
||||
uid: req.params.uid,
|
||||
madeby: config.branding[1],
|
||||
madebysite: config.branding[2]
|
||||
madeby: config.http.branding[1],
|
||||
madebysite: config.http.branding[2]
|
||||
})
|
||||
} else {
|
||||
res.render(
|
||||
|
@ -49,8 +49,8 @@ router.get(
|
|||
{
|
||||
address: req.params.address,
|
||||
message: 'This mail could not be found. It either does not exist or has been deleted from our servers!',
|
||||
madeby: config.branding[1],
|
||||
madebysite: config.branding[2],
|
||||
madeby: config.http.branding[1],
|
||||
madebysite: config.http.branding[2],
|
||||
}
|
||||
)
|
||||
}
|
||||
|
|
|
@ -7,11 +7,11 @@ const config = require('../../../application/config')
|
|||
|
||||
router.get('/', (req, res, _next) => {
|
||||
res.render('login', {
|
||||
title: `${config.branding[0]} | Your temporary Inbox`,
|
||||
title: `${config.http.branding[0]} | Your temporary Inbox`,
|
||||
username: randomWord(),
|
||||
domains: config.email.domains,
|
||||
madeby: config.branding[1],
|
||||
madebysite: config.branding[2]
|
||||
madeby: config.http.branding[1],
|
||||
madebysite: config.http.branding[2]
|
||||
})
|
||||
})
|
||||
|
||||
|
@ -42,8 +42,8 @@ router.post(
|
|||
username: req.body.username,
|
||||
domain: req.body.domain,
|
||||
userInputError: true,
|
||||
madeby: config.branding[1],
|
||||
madebysite: config.branding[2]
|
||||
madeby: config.http.branding[1],
|
||||
madebysite: config.http.branding[2]
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue