mirror of
https://github.com/comatory/fb2iCal
synced 2025-06-05 22:09:25 +02:00
move app routes to separate directory for better composition in
preparation of firebase integration
This commit is contained in:
16
lib/routes/error.js
Normal file
16
lib/routes/error.js
Normal file
@ -0,0 +1,16 @@
|
||||
const error = (req, res) => {
|
||||
const error = req.error || req.query.error || ''
|
||||
|
||||
res
|
||||
.status(500)
|
||||
.render('error', { error })
|
||||
}
|
||||
|
||||
const notFound = (req, res) => {
|
||||
res.status(400).render('404')
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
error,
|
||||
notFound,
|
||||
}
|
Reference in New Issue
Block a user