if "admin" == request[1] then
require("luci.model.uci")
local ucic = 0
- for n, s in pairs(luci.model.uci.changes()) do
- for no, o in pairs(s) do
- ucic = ucic + 1;
+ local changes = luci.model.uci.changes()
+ if type(changes) == "table" then -- XXX: sometimes string or nil / needs investigation
+ for n, s in pairs(changes) do
+ for no, o in pairs(s) do
+ ucic = ucic + 1;
+ end
end
end
%>