You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 27, 2019. It is now read-only.
Currently, when the PermissionScope dialog is shown, and the user leaves the app using the "Show me" alert option to go to Settings, PermissionScope observes "UIApplicationDidBecomeActive" so that it can re-analyze the permissions (using the "detectAndCallback()" method) to sense and display changes when the user returns.
However, if, while the dialog is shown, the user manually leaves the app (using the Home button) and goes to the settings and changes something, when the user returns to the app, the dialog will not detect any change.
I see 2 possible fixes to this. The best way would be for PermissionScope to create that observer whenever the dialog is shown, not just when the "Show me" button is hit. That way, PermissionScope will be triggered to re-analyze permissions whenever the app returns.
The second way, which is not as preferable but was a minimal change I could make to "hack" my local copy to fix this situation, was to make the "detectAndCallback()" method public, so that I can call it manually when my app senses that it has become active. Again, this is not a preferable solution, but perhaps there are other reasons for an app to have access to "detectAndCallback()".
Thanks for a great library, by the way!
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Currently, when the PermissionScope dialog is shown, and the user leaves the app using the "Show me" alert option to go to Settings, PermissionScope observes "UIApplicationDidBecomeActive" so that it can re-analyze the permissions (using the "detectAndCallback()" method) to sense and display changes when the user returns.
However, if, while the dialog is shown, the user manually leaves the app (using the Home button) and goes to the settings and changes something, when the user returns to the app, the dialog will not detect any change.
I see 2 possible fixes to this. The best way would be for PermissionScope to create that observer whenever the dialog is shown, not just when the "Show me" button is hit. That way, PermissionScope will be triggered to re-analyze permissions whenever the app returns.
The second way, which is not as preferable but was a minimal change I could make to "hack" my local copy to fix this situation, was to make the "detectAndCallback()" method public, so that I can call it manually when my app senses that it has become active. Again, this is not a preferable solution, but perhaps there are other reasons for an app to have access to "detectAndCallback()".
Thanks for a great library, by the way!
The text was updated successfully, but these errors were encountered: