源代码
wx.makePhoneCall({ phoneNumber: app.globalData.phoneNumber, })
![](https://img2020.cnblogs.com/blog/1197012/202104/1197012-20210429102031958-872583110.png)
只需要在后面加上catch就可以解决这个报错
wx.makePhoneCall({ phoneNumber:app.globalData.phoneNumber, }).catch((e) => { // console.log(e) //用catch(e)来捕获错误{makePhoneCall:fail cancel} })
源代码
wx.makePhoneCall({ phoneNumber: app.globalData.phoneNumber, })
只需要在后面加上catch就可以解决这个报错
wx.makePhoneCall({ phoneNumber:app.globalData.phoneNumber, }).catch((e) => { // console.log(e) //用catch(e)来捕获错误{makePhoneCall:fail cancel} })