Skip to content

Commit

Permalink
luci-mod-status: use public interface of luci.model.network.wifinet
Browse files Browse the repository at this point in the history
changes to lede-1701
seems the same like openwrt/luci#569
  • Loading branch information
FreifunkUFO committed Feb 27, 2017
1 parent 56893fb commit 3d8d4c8
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -65,9 +65,9 @@ function action_json_stations(device)

local function network_links(ntm, net)
local station_links = {}
local macaddr = ntm:get_interface(net.iwdata.ifname):mac()
local macaddr = ntm:get_interface(net:ifname()):mac()
local channel = net:channel()
local assoclist = net.iwinfo.assoclist
local assoclist = net:assoclist()
local bat_hosts = dict_from_file("/etc/bat-hosts")
for station_mac, link_data in pairs(assoclist) do
local wifilink = {
Expand All @@ -82,7 +82,7 @@ function action_json_stations(device)
return station_links
end

local ntm = netm.init()
local ntm = require "luci.model.network".init()
local net = ntm:get_wifinet(device)
local net_links = network_links(ntm, net)

Expand Down

0 comments on commit 3d8d4c8

Please sign in to comment.