Fixed bug - deleted images did not remove the references to the images that they come from.