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.
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.