PHAuthorizationStatus status = [PHPhotoLibrary authorizationStatus];
You want to check the status of your photo access rights using the and the system pops up the first time you run it.
I want to return to the Not Determined state after allowing it.
Even if I delete the app and reinstall it, it says it's still authenticated. How do I get back to being undecided?
ios objective-c
It doesn't seem like there's a function that the app can it? You can change it in your own settings. But I don't think Not Determined will work and it will be Denied.
After the user grants permission, the system remembers the choice for
future use in your app, but the user can change this choice at any time
using the Settings app. If the user has denied your app photo library access,
not yet responded to the permission prompt, or cannot grant access due
to restrictions, any attempts to fetch photo library content will return
empty PHFetchResult objects, and any attempts to perform
changes to the photo library will fail.
This is the information from the Apple document. If you look at the first sentence,
Allow users to select user permissions The system remembers the options for future use in the app, but users can change the choices in the Settings app at any time.
I understand that it is impossible to change the code because the authority itself is the user's choice. And even if I delete the app, the downloaded app information remains on the iCloud, so that information is also there? I think it won't change.
© 2024 OneMinuteCode. All rights reserved.