olofd / react-native-photos-framework

A modern and comprehensive CameraRoll/iCloud-library-API for React Native 📸 📹
MIT License
220 stars 99 forks source link

Deleting an asset from a smart album #52

Open itechdom opened 7 years ago

itechdom commented 7 years ago

Thank you for this awesome library. I am running into an issue deleting an asset from a smart album. I am trying to delete an image from the Screenshots album to be exact. I am getting back this error as a Promise rejection when calling:

album.removeAsset(myAsset)

I am getting back this error:

Error: The operation couldn’t be completed. (Cocoa error -1.)
    at createErrorFromErrorData (NativeModules.js:116)
    at NativeModules.js:79
    at MessageQueue.__invokeCallback (MessageQueue.js:290)
    at MessageQueue.js:127
    at guard (MessageQueue.js:46)
    at MessageQueue.invokeCallbackAndReturnFlushedQueue (MessageQueue.js:126)
    at debuggerWorker.js:71

I googled Cocoa error -1, but I am not sure I found anything helpful.

Any help would be appreciated. Thanks again!

olofd commented 7 years ago

Still an issue? I can take a look at this during the week if it is.