fix: 补充类型

This commit is contained in:
ningmengchongshui 2024-06-09 20:36:10 +08:00
parent cf8e08c312
commit a79e7c16bc
3 changed files with 10 additions and 12 deletions

View File

@ -99,7 +99,6 @@ export default class MysApi {
return this.isSr ? 'prod_gf_cn' : 'cn_gf01'
}
_device_fp = null
/**
@ -109,7 +108,7 @@ export default class MysApi {
* @param cached
* @returns
*/
async getData(type, data:any = {}, cached = false) {
async getData(type, data: any = {}, cached = false) {
if (
!this._device_fp &&
!data?.Getfp &&
@ -145,8 +144,8 @@ export default class MysApi {
}
let param = {
method:null,
body:null,
method: null,
body: null,
headers,
agent: await this.getAgent(),
timeout: 10000
@ -158,9 +157,9 @@ export default class MysApi {
param.method = 'get'
}
let response = {
ok:null,
ok: null,
status: null,
statusText:null
statusText: null
}
let start = Date.now()
try {

View File

@ -240,7 +240,7 @@ export default class MysInfo {
static async get(e, api, data = {}, option = {}) {
let mysInfo = await MysInfo.init(e, api)
if(!mysInfo) return false
if (!mysInfo) return false
if (!mysInfo.uid || !mysInfo.ckInfo.ck) return false
e.uid = mysInfo.uid

View File

@ -49,14 +49,13 @@ export function mkdirs(dirname: string) {
}
}
/**
*
* @param cmd
* @returns
*
* @param cmd
* @returns
*/
export function execAsync(cmd: string): Promise<{
stdout: string,
stdout: string
stderr: string
}> {
return new Promise((resolve, reject) => {