Fix most glaring bugs and vulnerabilities

This commit is contained in:
Luka Romih
2023-05-08 23:25:25 +02:00
parent 9867875ef2
commit d0e53fee3b
144 changed files with 2231 additions and 2981 deletions
+1 -8
View File
@@ -13,7 +13,7 @@ router.get('/:dictionaryId/o-slovarju', dictionary.dictionaryDetails)
// All further routes are only available to authenticated users.
router.use((req, res, next) => {
if (req.isAuthenticated()) return next()
res.redirect(req.baseUrl)
res.redirect(303, req.baseUrl)
})
// Show a form to create a new dictionary.
@@ -92,13 +92,6 @@ router.get(
dictionary.showContent
)
// Validate and update dictionary content entries.
// router.post(
// '/:dictionaryId/vsebina',
// user.isDictionaryEditor,
// dictionary.updateContent
// )
// Show a form to export a dictionary.
router.get(
'/:dictionaryId/izvoz',