diff options
author | Jo-Philipp Wich <jo@mein.io> | 2021-10-11 20:01:39 +0300 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2021-10-11 20:02:18 +0300 |
commit | 4d28c390ab181636b101a17203b2db3391784687 (patch) | |
tree | db74daa35942d264607c56c4d5f5147ddc56c389 /modules | |
parent | 34b682afac310859f0d4696110d8a1af60f16c04 (diff) |
luci-base: dispatcher: fix null access on dispatching unknown urls
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'modules')
-rw-r--r-- | modules/luci-base/luasrc/dispatcher.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/luci-base/luasrc/dispatcher.lua b/modules/luci-base/luasrc/dispatcher.lua index 2f965b16a8..bd1b112f60 100644 --- a/modules/luci-base/luasrc/dispatcher.lua +++ b/modules/luci-base/luasrc/dispatcher.lua @@ -918,7 +918,9 @@ function dispatch(request) return end - page.readonly = not perm + if page then + page.readonly = not perm + end end local action = (page and type(page.action) == "table") and page.action or {} |