Check we're not trying to delete default media thumbnails #854
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When using the "Delete media and files" views bulk operation on a FITS media type, for example, Drupal comes back saying we don't have permission to delete "x" number of files. This is because one of the files it is trying to delete is the default thumbnail for the media type. This is confusing to clients and so I suggest we remove default thumbnails from the list of inaccessible entities.
GitHub Issue: (link)
What does this Pull Request do?
Removes default thumbnails from the list of inaccessible entities when deleting multiple media and files.
What's new?
A in-depth description of the changes made by this PR. Technical details and
possible side effects.
How should this be tested?
Create a media item on a repository item which uses a default thumbnail (eg: FITs), then use the "Delete media and files" action on it and you should see a warning: "X items have not been deleted because you do not have the necessary permissions".
Checkout this pull request branch, repeat steps above and you should not see the warning.
Documentation Status
This is under-the-hood, shouldn't need any docs updated.
Additional Notes:
Let me know if I'm using the system incorrectly, and/or whether there is a better solution to this.
Interested parties
Tag (@ mention) interested parties or, if unsure, @Islandora/8-x-committers