Karumi / Dexter

Android library that simplifies the process of requesting permissions at runtime.
http://karumi.com
Apache License 2.0
5.23k stars 671 forks source link

Permissions denied via Settings are still treated as granted #88

Closed oseparovic closed 8 years ago

oseparovic commented 8 years ago

Expected behaviour

Denied permission brings up dialog to accept permission again when relevant action is performed

Actual behaviour

Denied permission is seen as granted even after app is killed and restarted

Steps to reproduce

  1. Accept permission via popup presented Dexter.checkPermission(listener, Manifest.permission.WRITE_EXTERNAL_STORAGE)
  2. Go to Settings > Apps > Your app > deny Storage permission
  3. Go back into app and perform same action. onPermissionGranted is still triggered and no popup to accept Storage permission is presented

    Version of the library

compile 'com.karumi:dexter:2.3.1' targetSdkVersion 23 Android 6.0.1 OnePlus 3

Serchinastico commented 8 years ago

Hi @oseparovic

I just tried with the last version sample project and looks like its working fine. After manually denying the storage permission, Dexter shows the rationale dialog.

Let me ask you some questions to try to narrow down the issue:

oseparovic commented 8 years ago

100% my bad. Didn't call continuePermissionRequest in onPermissionRationaleShouldBeShown as you pointed out.

Thank you for the quick reply!