紧急wx.cloud.uploadFile 返回 fail url not in domain?
发布于 4 年前 作者 maolei 11514 次浏览 来自 官方Issues

过去代码运行正常,最近两天发现所有的wx.cloud.uploadFile 运行都不正常

该函数在开发环境和真机测试环境都正常,但在真机运行环境下出现错误:

fail url not in domain list?

代码片段:

	wx.cloud.uploadFile({ 			cloudPath: 'owner\_sound/share/' + that.data.news\_id + '/share.jpg', 			filePath: that.data.upload\_local\_url, // 本地文件路径 			success: res => { 				that.getImgUrl(res.fileID) 			}, 			fail: err => { 				that.setData({ 					publisher\_change: false, 				}) 				wx.hideLoading({           success: (res) => {             wx.showModal({               title: '封面图片上传失败!',               content: err.errMsg,               showCancel: false, 						})           },         }) 			} 		})
回到顶部