1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

Fix when using wizard but not setting IP

This commit is contained in:
Ycarus (Yannick Chabanois) 2020-08-24 17:14:46 +02:00
parent 099f4c82bf
commit a03d73bfc7

View file

@ -221,9 +221,15 @@ function wizard_add()
ucic:set("network",intf,"proto",proto)
end
ucic:set("network",intf,"label",label)
ucic:set("network",intf,"ipaddr",ipaddr)
ucic:set("network",intf,"netmask",netmask)
ucic:set("network",intf,"gateway",gateway)
if ipaddr ~= "" then
ucic:set("network",intf,"ipaddr",ipaddr)
ucic:set("network",intf,"netmask",netmask)
ucic:set("network",intf,"gateway",gateway)
else
ucic:set("network",intf,"ipaddr","")
ucic:set("network",intf,"netmask","")
ucic:set("network",intf,"gateway","")
end
ucic:delete("openmptcprouter",intf,"lc")
ucic:save("openmptcprouter")