Corrected image cropping bug