summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua
diff options
context:
space:
mode:
Diffstat (limited to 'applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua')
-rw-r--r--applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua21
1 files changed, 2 insertions, 19 deletions
diff --git a/applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua b/applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua
index b9704cdb41..ea65263996 100644
--- a/applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua
+++ b/applications/luci-radvd/luasrc/model/cbi/radvd/rdnss.lua
@@ -91,27 +91,10 @@ end
o = s:option(Value, "AdvRDNSSLifetime", translate("Lifetime"),
- translate("Specifies the maximum duration how long the RDNSS entries are used for name resolution. Use 0 to specify an infinite lifetime"))
+ translate("Specifies the maximum duration how long the RDNSS entries are used for name resolution."))
-o.datatype = "uinteger"
+o.datatype = 'or(uinteger,"infinity")'
o.placeholder = 1200
-function o.cfgvalue(self, section)
- local v = Value.cfgvalue(self, section)
- if v == "infinity" then
- return 0
- else
- return v
- end
-end
-
-function o.write(self, section, value)
- if value == "0" then
- Value.write(self, section, "infinity")
- else
- Value.write(self, section, value)
- end
-end
-
return m