# HG changeset patch # User bsw # Date 1643889375 -3600 # Node ID ed156969a4475b7f3cd0452b85c68a764e2b5c11 # Parent 1dad272c08eb2af5a98038c85f4b3e95a85ac933 Handle selecting different unit in issue filters diff -r 1dad272c08eb -r ed156969a447 app/main/index/index.lua --- a/app/main/index/index.lua Thu Feb 03 12:44:02 2022 +0100 +++ b/app/main/index/index.lua Thu Feb 03 12:56:15 2022 +0100 @@ -27,8 +27,13 @@ if area_id then area = Area:by_id(area_id) if not area or (unit and area.unit_id ~= unit.id) then - execute.view { module = "index", view = "404" } - request.set_status("404 Not Found") + request.redirect{ + external = encode.url{ + module = "index", view = "index", params = { + unit = unit_id + } + } + } return end area:load_delegation_info_once_for_member_id(app.session.member_id)