stadiamaps / stadiamaps/ferrostar

Android - Stale LastLocation causes immediate reroute with FusedLocationProvider

Open
#412 0 comments 0 reactions 1 assignee Claimed by @Archdoog View on GitHub
android bug
Dominant language
Kotlin
Stars
419
Forks
81
Avg merge
6d 1h
Merged PRs (30d)
7

Description

When the location provider is run for a while, then stopped, but not deinitialized it can emit a stale initial location to ferrostar core, causing the map to jump to a location the user was at historically. See:

```kotlin
if (lastLocation == null) {
fusedLocationProviderClient.lastLocation.addOnSuccessListener { location ->
if (location != null) {
androidListener.onLocationChanged(location)
}
}
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.