Resize the image while saving the response