* luci/themes: do an explicit check for table data type on result of uci.changes()
This commit is contained in:
parent
48e06817da
commit
788cbb2633
2 changed files with 2 additions and 2 deletions
|
@ -122,7 +122,7 @@ end
|
||||||
require("luci.model.uci")
|
require("luci.model.uci")
|
||||||
local ucic = 0
|
local ucic = 0
|
||||||
local changes = luci.model.uci.changes()
|
local changes = luci.model.uci.changes()
|
||||||
if changes then
|
if type(changes) == "table" then -- XXX: sometimes string or nil / needs investigation
|
||||||
for n, s in pairs(changes) do
|
for n, s in pairs(changes) do
|
||||||
for no, o in pairs(s) do
|
for no, o in pairs(s) do
|
||||||
ucic = ucic + 1;
|
ucic = ucic + 1;
|
||||||
|
|
|
@ -122,7 +122,7 @@ end
|
||||||
require("luci.model.uci")
|
require("luci.model.uci")
|
||||||
local ucic = 0
|
local ucic = 0
|
||||||
local changes = luci.model.uci.changes()
|
local changes = luci.model.uci.changes()
|
||||||
if changes then
|
if type(changes) == "table" then -- XXX: sometimes string or nil / needs investigation
|
||||||
for n, s in pairs(changes) do
|
for n, s in pairs(changes) do
|
||||||
for no, o in pairs(s) do
|
for no, o in pairs(s) do
|
||||||
ucic = ucic + 1;
|
ucic = ucic + 1;
|
||||||
|
|
Loading…
Reference in a new issue