mirror of
https://github.com/Luzifer/gpxhydrant.git
synced 2024-12-22 12:11:17 +00:00
Fix: All values need to be evaluated, switch is bad
This commit is contained in:
parent
97b39d3c64
commit
cba51a2052
1 changed files with 7 additions and 5 deletions
12
main.go
12
main.go
|
@ -205,14 +205,16 @@ func main() {
|
|||
}
|
||||
hydrants = append(hydrants, h)
|
||||
|
||||
switch {
|
||||
case minLat > h.Latitude:
|
||||
if minLat > h.Latitude {
|
||||
minLat = h.Latitude
|
||||
case maxLat < h.Latitude:
|
||||
}
|
||||
if maxLat < h.Latitude {
|
||||
maxLat = h.Latitude
|
||||
case minLon > h.Longitude:
|
||||
}
|
||||
if minLon > h.Longitude {
|
||||
minLon = h.Longitude
|
||||
case maxLon < h.Longitude:
|
||||
}
|
||||
if maxLon < h.Longitude {
|
||||
maxLon = h.Longitude
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue