react-native-background-geolocation
react-native-background-geolocation copied to clipboard
[CHANGEME] this app collects location data for FEATURE X and FEATURE Y
How can I change this message, and from where this message is triggering automatically in android
See Config.backgroundPermissionRationale
I've tried this and the message remains. Do I need to do anything else?
Likely because you sent reset: false
to .ready, causing your Config changes to be ignored.
Doesn't seem to be that, this is my config.
await BackgroundGeolocation.ready({
locationAuthorizationRequest: 'WhenInUse',
backgroundPermissionRationale: {
title: "Allow {applicationName} to access to this device's location when closed or not in use?",
message:
"If you would like to receive a notification when you are at an {applicationName} compatible venue then you'll need to enable {backgroundPermissionOptionLabel} location permission",
positiveAction: 'Change to {backgroundPermissionOptionLabel}',
negativeAction: 'Cancel',
},
disableLocationAuthorizationAlert: true,
geofenceModeHighAccuracy: true,
desiredAccuracy: BackgroundGeolocation.DESIRED_ACCURACY_NAVIGATION,
distanceFilter: 5,
stopTimeout: 5,
foregroundService: true,
debug: config.DEBUG_LOCATION_SOUNDS === 'true',
logLevel: __DEV__ ? BackgroundGeolocation.LOG_LEVEL_VERBOSE : BackgroundGeolocation.LOG_LEVEL_OFF,
stopOnTerminate: false,
startOnBoot: true,
geofenceInitialTriggerEntry: false,
isMoving: true,
transistorAuthorizationToken,
})
I'm also trying to find the text "CHANGEME" or "FEATURE" in either the react-native-background-geolocation-android
, or react-native-background-fetch
modules but can't find it. Is this a dialog triggered by Android itself or the RNBGL module?
Should I create a new issue for this?
Then you are calling getCurrentPosition() before .ready() resolves.
ah okay, that could very well be it. I will take a look. Thanks.
You aren’t supposed to call .start() until .ready() resolves.
the plugin is not ready until .ready() resolves. It is called ready on purpose.
Could this result from calling getProviderState before .ready() resolves? Is it safe to say that no methods from the plugin should be used until after .ready() resolves?
Could this result from calling getProviderState before
No.
Is it safe to say that
No. Only methods which request location. .start(), .getCurrentPosition(). Those methods will request location permission.
Your Config provided to .ready() is not consumed until .ready() resolves.
If you cause the plugin to request permission before your Config is applied, then the plugin will use its current default values.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. You may also mark this issue as a "discussion" and I will leave this open.
Closing this issue after a prolonged period of inactivity. Fell free to reopen this issue, if this still affecting you.