fix ethinfo
This commit is contained in:
parent
f0fb9596e8
commit
d12ebf7386
@ -12,7 +12,7 @@ for ifname, stat in pairs(util.ubus("network.device", "status")) do
|
||||
|
||||
status = stat.carrier and "yes" or "no"
|
||||
|
||||
if stat.speed:sub(1, 1) == "-" then
|
||||
if stat.speed == nil or stat.speed:sub(1, 1) == "-" then
|
||||
speed = "-"
|
||||
else
|
||||
speed = stat.speed:sub(1, -2) .. "Mb/s"
|
||||
|
Loading…
x
Reference in New Issue
Block a user