1
votes

I am developing a React Native app which needs permission of location and storage. I've added needed permissions to AndroidManifest.xml and by default permissions are granted after app installation.

But if use try to deny the permissions from app settings page (as you can see in the screenshot below), the PermissionsAndroid.request can not find the permissions are denied and always returns authorized.

enter image description here

Is there any way to find if user has denied the permissions after app installed?

1

1 Answers

1
votes

I've used this library for the purpose, and more specifically from the example:

Permissions.checkMultiple(['camera', 'photo'])
  .then(response => {
    //response is an object mapping type to permission
    this.setState({
      cameraPermission: response.camera,
      photoPermission: response.photo,
    })
  });