请求接口的方法中没有 catch,加上即可。
async getCode() {
try {
const res = await this.getCodeAsync()
} catch (err) {
console.log(err)
}
}
请求接口的方法中没有 catch,加上即可。
async getCode() {
try {
const res = await this.getCodeAsync()
} catch (err) {
console.log(err)
}
}