Feature request from schnappenberger, posted on GitHub Nov 09, 2016
if you delete an image a.jpg from a product A gallery and have another product B which uses a.jpg, then a.jpg will be deleted in file system and product B looses this image also.
Preconditions
- Magento 2.1.2
 
- PHP7
 
- Apache 2
 
- Mysql 5
 
Steps to reproduce
- Import some Products with the same image gallery
 
- Open a product in admin and delete an image, which is used in other products
 
- Have a look on the gallery of the other products
 
Expected result
- Image relation is deleted from database, the image in filesystems stays if there are relations from other products
 
- Image in filesystem is only deleted if there are no other relations
 
Actual result
- Image relation in database and in filesystem is deleted
 
- Other products which uses this image have now a relation to a non existing image file