summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorDirk Brenken <dev@brenken.org>2018-03-16 06:37:08 +0100
committerGitHub <noreply@github.com>2018-03-16 06:37:08 +0100
commit7656f51c82ea490589b40ba19ff5eced672251b5 (patch)
tree7a303d5f43347bbe87b5d910786a203a1444650e
parent44132150fc71b6aac0a9e8723bc8efe16bd8104c (diff)
parent14bdc24d4ad421cd8b1f796b4b09affc5ed45e08 (diff)
Merge pull request #1686 from dibdot/wifischedule
luci-app-wifischedule: fix function calls
-rw-r--r--applications/luci-app-wifischedule/luasrc/model/cbi/wifischedule/wifi_schedule.lua7
1 files changed, 4 insertions, 3 deletions
diff --git a/applications/luci-app-wifischedule/luasrc/model/cbi/wifischedule/wifi_schedule.lua b/applications/luci-app-wifischedule/luasrc/model/cbi/wifischedule/wifi_schedule.lua
index 1d301219a..07730225b 100644
--- a/applications/luci-app-wifischedule/luasrc/model/cbi/wifischedule/wifi_schedule.lua
+++ b/applications/luci-app-wifischedule/luasrc/model/cbi/wifischedule/wifi_schedule.lua
@@ -12,8 +12,9 @@
--
-- Author: Nils Koenig <openwrt@newk.it>
-local fs = require "nixio.fs"
+local fs = require "nixio.fs"
local sys = require "luci.sys"
+local uci = require("luci.model.uci").cursor()
function time_validator(self, value, desc)
if value ~= nil then
@@ -110,7 +111,7 @@ modules.wrap = "off"
modules.rows = 10
function modules.cfgvalue(self, section)
- mod = uci.get("wifi_schedule", section, "modules")
+ mod = uci:get("wifi_schedule", section, "modules")
if mod == nil then
mod = ""
end
@@ -121,7 +122,7 @@ function modules.write(self, section, value)
if value then
value_list = value:gsub("\r\n", " ")
ListValue.write(self, section, value_list)
- uci.set("wifi_schedule", section, "modules", value_list)
+ uci:set("wifi_schedule", section, "modules", value_list)
end
end
-- END Modules