diff --git a/luci-app-openmptcprouter/root/usr/libexec/rpcd/openmptcprouter b/luci-app-openmptcprouter/root/usr/libexec/rpcd/openmptcprouter index cf6f7ae29..25b6e20b2 100755 --- a/luci-app-openmptcprouter/root/usr/libexec/rpcd/openmptcprouter +++ b/luci-app-openmptcprouter/root/usr/libexec/rpcd/openmptcprouter @@ -1193,12 +1193,12 @@ function interfaces_status() if connectivity ~= "ERROR" then if ifname ~= nil and ifname:match("^tun.*") and interface:match("^ovpn.*") then publicIP = uci:get("openmptcprouter",interface:sub(5),"publicip") or "" - if ifname ~= nil and publicIP == "" and mArray.openmptcprouter["external_check"] ~= false then + if ifname ~= nil and publicIP == "" and mArray.openmptcprouter["external_check"] ~= false and mArray.openmptcprouter["dns"] == true then publicIP = ut.trim(sys.exec("omr-ip-intf " .. get_device(interface:sub(5)))) end else publicIP = uci:get("openmptcprouter",interface,"publicip") or "" - if ifname ~= nil and publicIP == "" and mArray.openmptcprouter["external_check"] ~= false then + if ifname ~= nil and publicIP == "" and mArray.openmptcprouter["external_check"] ~= false and mArray.openmptcprouter["dns"] == true then publicIP = ut.trim(sys.exec("omr-ip-intf " .. ifname)) end end