6.0
This release contains breaking API changes:
-
The following methods do not return results anymore:
suspend fun requestLocationPermissions()
suspend fun requestEnableLocationSettings()
The reason for the change is that waiting for an ActivityResult
and holding onto the coroutine continuation meanwhile is inherently
unsafe.Users should observe the following flows to get the results:
permissionStatus
settingsStatus
Non-breaking API changes:
- New builders:
ComponentActivity.locationFetcher(config: LocationFetcher.Config.() -> Unit)
Context.locationFetcher(config: LocationFetcher.Config.() -> Unit)
Other changes:
- Added configuration option
isWaitForAccurateLocation
for LocationRequest
providers. - Receive location on a worker thread.
- Bump versions and migrate gradle files from Groovy to Kotlin (.kts).
- Depend on ComponentActivity instead of FragmentActivity.