-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Android] [Crashed] App crashed after update the device setting #341
Comments
Error looks like you need to add the |
Hi @kenjdavidson, thank you for responding.
The issue never happens if the user accepts/allows the permission request. |
That sounds about right, there is information on the React Native site (and maybe these docs) saying that you need to manage that, you shouldn't be attempting to access anything without requesting permission. You should be able to handle that by wrapping all the bluetooth logic in a wrapper that checks if they've already give permission. |
https://kenjdavidson.com/react-native-bluetooth-classic/android/#android-permissions If you feel like this needs more information, once you sort it out feel free to open a PR updating the docs for future users. |
@kenjdavidson The |
If you figure it out, please open a PR and we can get the fix in. I'm not sure there is much I can do as I don't have access to this code nor do I really do Mobile/React Native development anymore - so I'm well out of the loop of what's going on. I'm really just maintaining the library as others use it. If I get some time, I can look around for docs and issues, but at this point you're going to need to do a little debugging and try to work it out. Sorry. |
I would start by wrapping the line in question Line 361 in 7e5c889
You should be able to make these changes locally for testing. |
Mobile Device Environment
Provide a list of operating systems on which this issue is relevant.
Application Environment
Provide information about your development environment:
Describe the bug
To Reproduce
function
onHostDestroy
is trigered and throw the exception.Screenshots
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: