diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2012-06-26 21:49:24 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2012-06-26 21:49:24 +0000 |
commit | 61883f2c3fdad559dd1362ca76c258793cd32c82 (patch) | |
tree | 2dfcf7617d5e94354c5d895ca9a14addd2690829 | |
parent | d52859b37ea6b2ab92de9cf5cfa3882b5ee3ff11 (diff) |
libs/core: fix network is_empty() check for wifi-ifaces which are part of multiple networks
-rw-r--r-- | libs/core/luasrc/model/network.lua | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/libs/core/luasrc/model/network.lua b/libs/core/luasrc/model/network.lua index d06216433..1764a3d41 100644 --- a/libs/core/luasrc/model/network.lua +++ b/libs/core/luasrc/model/network.lua @@ -782,9 +782,12 @@ function protocol.is_empty(self) _uci_real:foreach("wireless", "wifi-iface", function(s) - if s.network == self.sid then - rv = false - return false + local n + for n in utl.imatch(s.network) do + if n == self.sid then + rv = false + return false + end end end) |