allowIdenticalLocations property

bool? allowIdenticalLocations
getter/setter pair

[Android only] Allow recording locations which are duplicates of the previous.

By default, the Android plugin will ignore a received location when it is identical to the previous location. Set true to override this behavior and record every location, regardless if it is identical to the last location.

In the logs, you will see a location being ignored:

TSLocationManager:   ℹ️ IGNORED: same as last location

An identical location is often generated when changing state from stationary -> moving, where a single location is first requested (the BackgroundGeolocation.onMotionChange location) before turning on regular location updates. Changing geolocation config params can also generate a duplicate location (eg: changing distanceFilter).

Implementation

bool? allowIdenticalLocations;