Kjuly / ALAssetsLibrary-CustomPhotoAlbum

A nice ALAssetsLibrary category for saving images & videos into custom photo album.
http://www.touch-code-magazine.com/ios5-saving-photos-in-custom-photo-album-category-for-download/
MIT License
405 stars 101 forks source link

Can not create album with name similar to deleted album #15

Closed phamquy closed 9 years ago

phamquy commented 10 years ago

When i try to save photo to album with same name as a deleted album. New album can not be created. Image is stilled added to library The album is just not created. No error is returned.

Kjuly commented 10 years ago

Oh, sorry, missed ur issue.. lol

Will take a look at it when i've got time :)

Kjuly commented 9 years ago

I'm afraid it's SDK's bug, someone else got this issue either: http://stackoverflow.com/questions/26003211/assetslibrary-framework-broken-on-ios-8

I debugged the code, and found the ALAssetsGroup will return all albums included deleted ones.

[group valueForProperty:ALAssetsGroupPropertyName]

even tried to re-add the album but still not works, the only way left is to create a new album. Seems there's also no way to check whether the album is deleted. It sucks.


And b.t.w., from iOS 8, maybe u can choose to use Photo Kit.

sarperdag commented 9 years ago

You can't really use Photo kit if you want iOS7 compatibility so, this is quite a headache for now.

Kjuly commented 9 years ago

@sarperdag yeah, really bad.

Kjuly commented 9 years ago

Issue was fixed by PR https://github.com/Kjuly/ALAssetsLibrary-CustomPhotoAlbum/pull/19