luci-mod-freifunk: eliminate use of luci.sys.net.deviceinfo()
authorJo-Philipp Wich <jo@mein.io>
Mon, 10 Jul 2017 14:07:21 +0000 (16:07 +0200)
committerJo-Philipp Wich <jo@mein.io>
Tue, 11 Jul 2017 12:05:31 +0000 (14:05 +0200)
The result of the luci.sys.net.deviceinfo() call was never actually used
anywhere in the following code, so simply drop the invocation.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
modules/luci-mod-freifunk/luasrc/controller/freifunk/freifunk.lua

index 84669dc..e2291e5 100644 (file)
@@ -70,7 +70,7 @@ function index()
        page.target = cbi("freifunk/basics")
        page.title  = _("Basic Settings")
        page.order  = 5
        page.target = cbi("freifunk/basics")
        page.title  = _("Basic Settings")
        page.order  = 5
-       
+
        page        = node("admin", "freifunk", "basics", "profile")
        page.target = cbi("freifunk/profile")
        page.title  = _("Profile")
        page        = node("admin", "freifunk", "basics", "profile")
        page.target = cbi("freifunk/profile")
        page.title  = _("Profile")
@@ -102,7 +102,7 @@ function zeroes()
        local zeroes = string.rep(string.char(0), 8192)
        local cnt = 0
        local lim = 1024 * 1024 * 1024
        local zeroes = string.rep(string.char(0), 8192)
        local cnt = 0
        local lim = 1024 * 1024 * 1024
-       
+
        http.prepare_content("application/x-many-zeroes")
 
        while cnt < lim do
        http.prepare_content("application/x-many-zeroes")
 
        while cnt < lim do
@@ -188,7 +188,6 @@ function jsonstatus()
        root.network = {}
        root.wireless = {devices = {}, interfaces = {}, status = {}}
        local wifs = root.wireless.interfaces
        root.network = {}
        root.wireless = {devices = {}, interfaces = {}, status = {}}
        local wifs = root.wireless.interfaces
-       local netdata = luci.sys.net.deviceinfo() or {}
 
        for _, vif in ipairs(ffwifs) do
                root.network[vif] = cursor:get_all("network", vif)
 
        for _, vif in ipairs(ffwifs) do
                root.network[vif] = cursor:get_all("network", vif)