mirror of
https://github.com/YunoHost/SSOwat.git
synced 2024-09-03 20:06:27 +02:00
Merge pull request #109 from tituspijean/mod-redirect-logout
[mod] Redirect after logout if `r` URI argument exists
This commit is contained in:
commit
3ad215124c
1 changed files with 6 additions and 2 deletions
|
@ -889,9 +889,13 @@ function logout()
|
||||||
flash("info", t("logged_out"))
|
flash("info", t("logged_out"))
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Redirect to portal anyway
|
-- Redirect with the `r` URI argument if it exists or redirect to portal
|
||||||
|
if args.r then
|
||||||
|
return redirect(ngx.decode_base64(args.r))
|
||||||
|
else
|
||||||
return redirect(conf.portal_url)
|
return redirect(conf.portal_url)
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
-- Set cookie and redirect (needed to properly set cookie)
|
-- Set cookie and redirect (needed to properly set cookie)
|
||||||
|
|
Loading…
Reference in a new issue