Please provide the following:
- SDK Version: v0.35.0
- Platforms(Android/iOS/web/all): IOS
Hi I am currently seeing two minor problems for background location tasks.
1, When the app first ask me for permission, even if I selected while in use(there is no option at first to say Always), the
Permissions.askAsync(Permissions.LOCATION); would still say the scope was
always. This can be annoying because I do not want the background task to run with the blue indicator later on.
2, After running in the background for a while, IOS will ask me if I want to change the permission to
Always, my app would immediately throw a promise rejection during this part
[Unhandled promise rejection: Error: Cannot obtain current location: Error Domain=kCLErrorDomain Code=0 "(null)"] - node_modules/react-native/Libraries/BatchedBridge/NativeModules.js:155:41 in createErrorFromErrorData - node_modules/react-native/Libraries/BatchedBridge/NativeModules.js:104:55 in <unknown> - ... 5 more stack frames from framework internals
I was wondering is there any way for me to catch this error?
Thanks in advance if anyone can help me with these problems, really appreciate it.