1
0
mirror of https://github.com/freifunk-gluon/packages.git synced 2024-06-13 10:49:17 +02:00

gluon-config-mode: fix coordinates when disabled

This commit is contained in:
Nils Schneider 2014-03-02 19:28:59 +01:00
parent 9aa4a147aa
commit b9a1de7286

View File

@ -118,7 +118,7 @@ function f.handle(self, state, data)
local sname = uci:get_first("gluon-node-info", "location")
uci:set("gluon-node-info", sname, "share_location", data._location)
if data._location then
if data._location and data._latitude ~= nil and data._longitude ~= nil then
uci:set("gluon-node-info", sname, "latitude", data._latitude)
uci:set("gluon-node-info", sname, "longitude", data._longitude)
end