liquid_feedback_frontend
changeset 1660:cbce4491c93e
Redirect to login from index page when no access rights
author | bsw |
---|---|
date | Sun Feb 14 13:35:16 2021 +0100 (2021-02-14) |
parents | 4b74a177884b |
children | fa9e93235e02 |
files | app/main/_filter/21_auth.lua app/main/index/index.lua |
line diff
1.1 --- a/app/main/_filter/21_auth.lua Sun Feb 14 13:29:56 2021 +0100 1.2 +++ b/app/main/_filter/21_auth.lua Sun Feb 14 13:35:16 2021 +0100 1.3 @@ -5,8 +5,7 @@ 1.4 local auth_needed = true 1.5 1.6 if module == 'index' and ( 1.7 - view == 'index' 1.8 - or view == "login" 1.9 + view == "login" 1.10 or action == "login" 1.11 or view == "register" 1.12 or action == "register"
2.1 --- a/app/main/index/index.lua Sun Feb 14 13:29:56 2021 +0100 2.2 +++ b/app/main/index/index.lua Sun Feb 14 13:35:16 2021 +0100 2.3 @@ -1,8 +1,3 @@ 2.4 -if not app.session:has_access("anonymous") then 2.5 - slot.put("<br /> Closed user group, please login.<br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />") 2.6 - return 2.7 -end 2.8 - 2.9 local unit_id = request.get_param{ name = "unit" } 2.10 local area_id = request.get_param{ name = "area" } 2.11