Open v-mauna opened 4 weeks ago
You don’t have to delete your app. Just go to your App settings and change location permission “Ask Next Time”.
The issue I'm seeing is that when the app's permissions are set to "Always" but the location services for the device are off, the prompt displayed reads:
Location Services Are Off. To use background location, you must enable 'Always' in the location services settings
. After deleting, it will show the alert specific to the device's location services, not the app's permissions.
The OS gives your app only one chance to show the native dialog to select permission.
thereafter, it will never be shown again until you select “Ask Next Time”.
See api docs Config.locationAuthorizationAlert
Ionic React Capacitor App All latest versions of all dependencies.
When testing on the iPhone 16 Pro running 18.0.1, and using the latest plugin of 6.1.2, the same prompt is shown when the device's location services are off and the app's location permissions are turned off. It requires deleting and reinstalling the app to trigger the correct prompt for the device's location services. Is there a way to update the config for the plugin to determine which is the correct prompt to show?
Current Plugin Config:
{ distanceFilter: 10, stopTimeout: 5, locationAuthorizationRequest: 'Always', desiredAccuracy: BackgroundGeolocation.DESIRED_ACCURACY_HIGH, logLevel: BackgroundGeolocation.LOG_LEVEL_INFO, backgroundPermissionRationale: { title: "Allow MAS Trips to access to this device's location in the background?", message: 'In order to track location changes in the background, please enable background location access.', positiveAction:
Change background location access to Always?, }, preventSuspend: true, // TODO: [iOS Only] this can stay true since we are turning the plugin on and off based on active rides }