googlesamples / easypermissions

Simplify Android M system permissions
https://firebaseopensource.com/projects/googlesamples/easypermissions/
Apache License 2.0
9.86k stars 1.46k forks source link

somePermissionPermanentlyDenied() returning always true #277

Closed mianaliasjad closed 5 years ago

mianaliasjad commented 5 years ago

somePermissionPermanentlyDenied in onPermissionsDenied is retuning always true. I have check this issue on 2 devices lg v20 (8.0) and lg g5 (6.0.1). Same results on both devices. If user simple deny the permission not "don't ask again" then somePermissionPermanentlyDenied is retuning true.

mianaliasjad commented 5 years ago

That was my mistake. In my app there was one activity and many fragments. I was requesting permission in fragments but it is android behavior that if a fragment request permission then onRequestPermissionsResult of activity is also called. Hope it will help someone in the future.