* make use of luci.model.uci to fix #1740
Signed-off-by: Dirk Brenken <dev@brenken.org>
translate("This displays the metric assigned to this interface in /etc/config/network"))
metric.rawhtml = true
function metric.cfgvalue(self, s)
translate("This displays the metric assigned to this interface in /etc/config/network"))
metric.rawhtml = true
function metric.cfgvalue(self, s)
- local uci = uci.cursor(nil, "/var/state")
+ local uci = require "luci.model.uci".cursor(nil, "/var/state")
local metric = uci:get("network", arg[1], "metric")
if metric then
return metric
local metric = uci:get("network", arg[1], "metric")
if metric then
return metric