PR for #2552 : Updating an image that is used on a page gives a 404 for the image

This is the Pull Request for #2552 the discussion is there.