Fixed luci.config
This commit is contained in:
parent
4483ebd74d
commit
a8a72c1ec8
1 changed files with 6 additions and 11 deletions
|
@ -25,14 +25,9 @@ limitations under the License.
|
||||||
|
|
||||||
]]--
|
]]--
|
||||||
|
|
||||||
local util = require "luci.util"
|
module("luci.config",
|
||||||
|
function(m)
|
||||||
local pcall = pcall
|
if pcall(require, "luci.model.uci") then
|
||||||
local require = require
|
setmetatable(m, {__index = luci.model.uci.cursor():get_all("luci")})
|
||||||
|
end
|
||||||
|
end)
|
||||||
module "luci.config"
|
|
||||||
|
|
||||||
pcall(function()
|
|
||||||
setmetatable(_M, {__index=require "luci.model.uci".cursor():get_all("luci")})
|
|
||||||
end)
|
|
Loading…
Reference in a new issue