fixed bug for upload local picture and clean codes

修复上传图片错误