Skip to content

Commit

Permalink
fix reading new area
Browse files Browse the repository at this point in the history
  • Loading branch information
pfeiferj committed Oct 29, 2023
1 parent b9769d4 commit b66d22b
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions mapd.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func main() {
if !PointInBox(pos.Latitude, pos.Longitude, state.Result.MinLat(), state.Result.MinLon(), state.Result.MaxLat(), state.Result.MaxLon()) {
res, err := FindWaysAroundLocation(pos.Latitude, pos.Longitude)
loge(err)
if err != nil {
if err == nil {
state.Result = res
}
}
Expand All @@ -93,7 +93,6 @@ func main() {
speedLimit = way.Way.MaxSpeed()
} else {
speedLimit = 0
lastSpeedLimit = 0
}

if state.Way.Way != (Way{}) && len(state.MatchingWays) > 0 {
Expand Down

0 comments on commit b66d22b

Please sign in to comment.