请问你的问题解决了吗?我也有同样的问题!
wx.getSetting一直失败体验版正常,线上不正常?wx.getSetting一直失败体验版正常,线上不正常,非常的离谱。 export const getSetting = () => { return new Promise((resolve, reject) => { wx.getSetting({ success(res) { if (!res.authSetting['scope.writePhotosAlbum']) { wx.authorize({ scope: 'scope.writePhotosAlbum', success() { resolve(); }, fail() { reject(); } }); } else { resolve(); } }, fail() { wx.authorize({ scope: 'scope.writePhotosAlbum', success() { resolve(); }, fail() { reject(); } }); } }); }); };
2023-08-14