🎨 根据实际情况修正

This commit is contained in:
BTMuli
2023-05-21 16:54:23 +08:00
parent 821014c0a2
commit 068f018d9e
7 changed files with 115 additions and 32 deletions

View File

@@ -7,4 +7,4 @@
const BBS_API = "https://bbs-api.miyoushe.com/"; // 基础 API
export const BBSUserInfoAPI = `${BBS_API}user/wapi/getUserFullInfo`; // 用户信息 API
export const BBSUserInfoApi = `${BBS_API}user/wapi/getUserFullInfo`; // 用户信息 API

View File

@@ -34,13 +34,12 @@ export async function getUserInfoByCookie (cookie_token: string, account_id: str
headers: header,
body: http.Body.json(params),
}).then((res) => {
console.log(res);
if (res.data.retcode !== 0) return res.data;
const info = res.data.data.user_info;
return {
nickname: info.nickname,
uid: info.uid,
avatar: info.avatar,
avatar: info.avatar_url,
desc: info.introduce,
};
});