projects
/
project
/
luci.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0f83d81
)
luci-base: dispatcher: remove empty firstchild nodes from menu
author
Jo-Philipp Wich
<jo@mein.io>
Fri, 10 Jan 2020 21:12:03 +0000
(22:12 +0100)
committer
Jo-Philipp Wich
<jo@mein.io>
Thu, 7 May 2020 17:40:49 +0000
(19:40 +0200)
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit
fd7961337f44ebe8aa71e6ae0925cb70a8c53b21
)
modules/luci-base/luasrc/dispatcher.lua
patch
|
blob
|
history
diff --git
a/modules/luci-base/luasrc/dispatcher.lua
b/modules/luci-base/luasrc/dispatcher.lua
index 6b10d49e5b156e9cc92d64bacc78b87b2660e365..32d34da012db296345dd956620d4b16c2a998a69 100644
(file)
--- a/
modules/luci-base/luasrc/dispatcher.lua
+++ b/
modules/luci-base/luasrc/dispatcher.lua
@@
-623,6
+623,14
@@
local function merge_trees(node_a, node_b)
node_a[k] = v
end
end
+
+ if type(node_a.action) == "table" and
+ node_a.action.type == "firstchild" and
+ node_a.children == nil
+ then
+ node_a.satisfied = false
+ end
+
return node_a
end