mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Fix if ifname not defined
This commit is contained in:
parent
1e4d24bdaa
commit
9bd6f555a4
1 changed files with 2 additions and 2 deletions
|
@ -243,14 +243,14 @@ function interfaces_status()
|
|||
-- Don't show if0 in the overview
|
||||
--if interface == "lo" then return end
|
||||
|
||||
local ifname = section['ifname']
|
||||
local ifname = section['ifname'] or ""
|
||||
if multipath == "off" and not ifname:match("^tun.*") then return end
|
||||
|
||||
local asn
|
||||
|
||||
local connectivity
|
||||
local multipath_state = ut.trim(sys.exec("multipath " .. ifname .. " | grep deactivated"))
|
||||
if multipath_state == "" then
|
||||
if multipath_state == "" and ifname ~= "" then
|
||||
connectivity = 'OK'
|
||||
else
|
||||
connectivity = 'ERROR'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue