From: Jo-Philipp Wich Date: Wed, 28 Jan 2009 18:26:07 +0000 (+0000) Subject: Merge r4176 X-Git-Tag: 0.8.5~20 X-Git-Url: http://207.154.207.93/?a=commitdiff_plain;h=1b4d4ff11a9d9cfe516b7d4ed85d603b6382b1c6;p=project%2Fluci.git Merge r4176 --- diff --git a/applications/luci-upnp/luasrc/model/cbi/upnp/upnp.lua b/applications/luci-upnp/luasrc/model/cbi/upnp/upnp.lua index 8d5a592b1..a48508129 100644 --- a/applications/luci-upnp/luasrc/model/cbi/upnp/upnp.lua +++ b/applications/luci-upnp/luasrc/model/cbi/upnp/upnp.lua @@ -16,6 +16,8 @@ m = Map("upnpd", translate("upnpd"), translate("upnpd_desc")) s = m:section(NamedSection, "config", "upnpd", "") e = s:option(Flag, "enabled", translate("enable")) +e.rmempty = false + function e.write(self, section, value) local cmd = (value == "1") and "enable" or "disable" os.execute("/etc/init.d/miniupnpd " .. cmd) diff --git a/applications/luci-upnp/luasrc/model/cbi/upnp/upnpmini.lua b/applications/luci-upnp/luasrc/model/cbi/upnp/upnpmini.lua index aaec3b0cc..8ad03a36a 100644 --- a/applications/luci-upnp/luasrc/model/cbi/upnp/upnpmini.lua +++ b/applications/luci-upnp/luasrc/model/cbi/upnp/upnpmini.lua @@ -16,6 +16,8 @@ m = Map("upnpd", translate("upnpd"), translate("upnpd_desc")) s = m:section(NamedSection, "config", "upnpd", "") e = s:option(Flag, "enabled", translate("enable")) +e.rmempty = false + function e.write(self, section, value) local cmd = (value == "1") and "enable" or "disable" os.execute("/etc/init.d/miniupnpd " .. cmd)