Search code examples
iosxamarinxamarin.formsxamarin.iosxamarin.essentials

iOS App Restarts After Changing Revoked Privacy Settings


No code to show, but merely a question on something that I'm sure has irked other developers/users.

When a user has revoked/denied permission to their Photos for a given app and then later changes to "Read and Write", the app resets/refreshes when opening it back up. Is there a way to not have the app reset/refresh when navigating back to the app? This is a concern because when the user is prompted to change their Photos permission, the user is deep within the app and now loses any progress made on that page after the permission is changed.

I am currently using Xamarin Essentials with Xamarin Forms, if that helps any.


Solution

  • It is designed by iOS system and your app is forced to restart when you change the privacy settings. I think there is no way to get around it.

    You can try to save the state in the method applicationDidEnterBackground and restore it when user come back again after changing the setting.

    Refer:

    Having app restart itself when it detects change to privacy settings

    App crashes in background while changing permission