In privacy settings, when I change the permissions related to iOS app (Camera or Microphone) and again back to the app then app restarting from initial state and I lost my existing state of work in the app.
Is there any way to save the last state or avoid killing/restart ?
Look at the applicationWillTerminate(_:) method. this will be called before Your app is killed and there is no way to stop it from restart when privacy permission is changed
Also take a look at this answer
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With