9

I would like to modify my app's behavior based on whether or not iCloud Photo Library is enabled or disabled. How does one determine that status?

And is there a way to subscribe to a notification such that if the user changes that setting my app would know and be able to update to reflect that new status?

Jordan H
  • 52,571
  • 37
  • 201
  • 351
  • I have not found any straight-forward way to do this. But the only sort of hack i have is by checking the localizedTitle of assetCollection with subType PHAssetCollectionSubtypeSmartAlbumUserLibrary. The localizedTitle will be "Camera Roll" for iCloud disabled devices & All Photos for iCloud enabled devices. But this can change in the future. – jarora Jun 07 '15 at 11:43
  • If you use PhotoKit, it doesn't matter to you whether your user is using iCloud Photo Library or not, it will give you all of the photos, and all you have to do request and wait while it downloads the photos that aren't currently on the device. Besides, it's a very terrible idea, probably the worst idea ever using a `localizedAnything` for anything. This name will be totally different for every language in the planet and your app will definitely not work correctly, while **also** changing with each iOS release – Velociround Oct 13 '15 at 18:58

0 Answers0