Fixed uploading image errors