This commit is contained in:
bbaban 2023-10-10 12:59:47 +08:00
parent af19c2959c
commit fc299a9628
1 changed files with 4 additions and 3 deletions

View File

@ -161,8 +161,9 @@ export default class MysInfo {
let user = e.user?.getMysUser()
let mysApi = new MysApi(mysInfo.uid, mysInfo.ckInfo.ck, option, e.isSr, user.device)
if (!data?.headers?.['x-rpc-device_fp']){
let device_fp = (await mysApi.getData('getFp')).data?.device_fp
let device_fp = ''
if (!data?.headers?.['x-rpc-device_fp']) {
device_fp = (await mysApi.getData('getFp')).data?.device_fp
if (data?.headers) {
data.headers['x-rpc-device_fp'] = device_fp
} else {
@ -178,7 +179,7 @@ export default class MysInfo {
let all = []
/** 同步请求 */
for (let i in api) {
if (!api[i]?.headers?.['x-rpc-device_fp']){
if (!api[i]?.headers?.['x-rpc-device_fp']) {
if (api[i]?.headers) {
api[i].headers['x-rpc-device_fp'] = device_fp
} else {