mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-12-18 05:43:05 -05:00
7b9f9a487b
Signed-off-by: David Mehren <git@herrmehren.de>
22 lines
515 B
TypeScript
22 lines
515 B
TypeScript
import { response } from '../response'
|
|
import { errors } from '../errors'
|
|
import { Router } from 'express'
|
|
|
|
const BaseRouter = Router()
|
|
|
|
// get index
|
|
BaseRouter.get('/', response.showIndex)
|
|
// get 403 forbidden
|
|
BaseRouter.get('/403', function (req, res) {
|
|
errors.errorForbidden(res)
|
|
})
|
|
// get 404 not found
|
|
BaseRouter.get('/404', function (req, res) {
|
|
errors.errorNotFound(res)
|
|
})
|
|
// get 500 internal error
|
|
BaseRouter.get('/500', function (req, res) {
|
|
errors.errorInternalError(res)
|
|
})
|
|
|
|
export { BaseRouter }
|