external login redirect, include logo images
This commit is contained in:
parent
1d782a9b98
commit
05588560a6
@ -62,10 +62,7 @@ function createSession (req, user) {
|
||||
|
||||
if (req.session.redirectUri) {
|
||||
uri = req.session.redirectUri
|
||||
delete req.session.redirectUri
|
||||
}
|
||||
|
||||
if (req.query.redirect) {
|
||||
} else if (req.query.redirect) {
|
||||
uri = req.query.redirect
|
||||
}
|
||||
|
||||
|
@ -38,6 +38,8 @@ function setSession (req, user) {
|
||||
|
||||
function redirectLogin (req, res) {
|
||||
let uri = '/'
|
||||
|
||||
console.log(req.session.redirectUri, req.session.csrf)
|
||||
if (req.session.redirectUri) {
|
||||
uri = req.session.redirectUri
|
||||
delete req.session.redirectUri
|
||||
|
@ -20,6 +20,7 @@ router.use(oauthLimiter)
|
||||
function ensureLoggedIn (req, res, next) {
|
||||
if (req.session.user) return next()
|
||||
req.session.redirectUri = req.originalUrl
|
||||
console.log('set return uri', req.session.redirectUri, req.session.csrf)
|
||||
res.redirect('/login')
|
||||
}
|
||||
|
||||
|
BIN
static/image/icynet-highres.png
Normal file
BIN
static/image/icynet-highres.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 201 KiB |
BIN
static/image/icynet-small.png
Normal file
BIN
static/image/icynet-small.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 37 KiB |
BIN
static/image/icynet.svgz
Normal file
BIN
static/image/icynet.svgz
Normal file
Binary file not shown.
@ -51,6 +51,8 @@ html
|
||||
a.scroll(href="/#home") Home
|
||||
li.fullview
|
||||
a.scroll(href="/#news") News
|
||||
li.fullview
|
||||
a(href="https://forum.icynet.eu/") Forum
|
||||
ul.fullview.floating
|
||||
if user
|
||||
li#user
|
||||
@ -69,6 +71,8 @@ html
|
||||
a.scroll(href="/#home") Home
|
||||
li
|
||||
a.scroll(href="/#news") News
|
||||
li
|
||||
a(href="https://forum.icynet.eu/") Forum
|
||||
.division
|
||||
if user
|
||||
li#user
|
||||
|
Reference in New Issue
Block a user