server: Fixed crash in auth failure redirect, added logging instead.
the build was successful

This commit is contained in:
2018-10-15 21:12:31 +02:00
parent 346bd7f70c
commit 0337424ab0
2 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@gisle/rpdata-frontend",
"version": "1.0.2",
"version": "1.0.3",
"description": "RPData (www.aiterp.net) frontend/proxy",
"main": "./index.js",
"scripts": {
+2 -1
View File
@@ -18,7 +18,8 @@ router.get("/login", saveReferer, passport.authenticate("auth0", {scope: "openid
})
router.get("/error", (req, res) => {
res.render("Login error")
console.error(req)
res.status(500).end("Something went wrong.")
})
router.get("/callback", passport.authenticate("auth0", { failureRedirect: "/auth/error" }), (req, res) => {