fix: 返回内容code类型处理

This commit is contained in:
binaryify 2023-09-09 21:46:03 +08:00
parent b6f6a87a86
commit 10d8ef5f43
2 changed files with 9 additions and 3 deletions

View File

@ -4211,9 +4211,11 @@ type='1009' 获取其 id, 如`/search?keywords= 代码时间 &type=1009`
### 验证接口-二维码生成
说明: 进行某些操作,如关注用户,可能会触发验证,可调用这个接口生成二维码,使用app扫码后可解除验证
**接口地址:** `/verify/getQr`
**必选参数:**
`vid`: 触发验证后,接口返回的verifyId
`type`:触发验证后,接口返回的verifyType
@ -4230,6 +4232,7 @@ type='1009' 获取其 id, 如`/search?keywords= 代码时间 &type=1009`
**接口地址:** `/verify/qrcodestatus`
**必选参数:**
`qr`: `/verify/getQr`接口返回的`qr`字符串
## 离线访问此文档

View File

@ -198,6 +198,9 @@ const createRequest = (method, url, data = {}, options) => {
} else {
answer.body = body
}
if (answer.body.code) {
answer.body.code = Number(answer.body.code)
}
answer.status = Number(answer.body.code || res.status)
if (