georgizk / ims-release

Imangascans release manager
MIT License
2 stars 0 forks source link

Release deletion errors if page does not exist in image folder #17

Closed georgizk closed 7 years ago

georgizk commented 7 years ago

If an image gets deleted from the image folder (via corruption or otherwise), the deletion of the release returns an error (since the image can't be found). However, the release actually does get deleted. The operation should either be made atomic, so that if deletion fails and an error is thrown, the release should remain in the database. Alternatively, you can go ahead and delete the release even when you fail to delete the file, but no error should be returned to make it clear that deletion succeeded (deletion failure should be silent). Silent option is probably preferable, otherwise it might be impossible to delete a release when files are missing.

georgizk commented 7 years ago

this is no longer an issue after api redesign (deleting a release with pages is not allowed)