summaryrefslogtreecommitdiffhomepage
path: root/libs/uvl
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2008-09-13 04:26:37 +0000
committerJo-Philipp Wich <jow@openwrt.org>2008-09-13 04:26:37 +0000
commita8d165a5bf5c40b277b9a2b841c3f83d9d213612 (patch)
treec890c48871e09967a30b309c5a467c0e545baddd /libs/uvl
parente898a0dec6d087216914590bbac57b8086f5cad3 (diff)
* luci/libs/uvl:
- only check option dependencies if option has a value - remove option required for atheros mode in wireless scheme - breaks broadcom * luci/model/admin-full: - override section validation if we create a new network on demand
Diffstat (limited to 'libs/uvl')
-rw-r--r--libs/uvl/luasrc/uvl.lua14
-rw-r--r--libs/uvl/root/lib/uci/schema/default/wireless3
2 files changed, 8 insertions, 9 deletions
diff --git a/libs/uvl/luasrc/uvl.lua b/libs/uvl/luasrc/uvl.lua
index f7943d8d7..c75b9bd7d 100644
--- a/libs/uvl/luasrc/uvl.lua
+++ b/libs/uvl/luasrc/uvl.lua
@@ -334,12 +334,12 @@ function UVL._validate_option( self, option, nodeps )
return false, option:error(ERR.OPT_DATATYPE(option, dt))
end
end
- end
- if not nodeps then
- local ok, err = dependencies.check( self, option )
- if not ok then
- option:error(err)
+ if not nodeps then
+ local ok, err = dependencies.check( self, option )
+ if not ok then
+ option:error(err)
+ end
end
end
@@ -848,7 +848,7 @@ function uvlitem.config(self, opt)
if #self.cref >= 3 then
c = c and c[self.cref[3]] or nil
end
- end
+ end
if c and opt then
return c[opt]
@@ -912,7 +912,7 @@ function uvlitem._loadconf(self, co, c)
if err then
self:error(ERR.UCILOAD(self, err))
end
-
+
self._configcache = co
end
return co
diff --git a/libs/uvl/root/lib/uci/schema/default/wireless b/libs/uvl/root/lib/uci/schema/default/wireless
index fa9598b84..562d1a44e 100644
--- a/libs/uvl/root/lib/uci/schema/default/wireless
+++ b/libs/uvl/root/lib/uci/schema/default/wireless
@@ -31,7 +31,6 @@ config variable
option name 'mode'
option section 'wireless.wifi-device'
option title 'Mode (atheros)'
- option required true
option type enum
list depends type=atheros
@@ -378,7 +377,7 @@ config variable
option title 'Encryption'
option description 'WPA-Encryption requires wpa_supplicant (for client mode) or hostapd (for AP and ad-hoc mode) to be installed.'
option type enum
-
+
config enum
option variable 'wireless.wifi-iface.encryption'
option value 'none'