diff --git a/src/store/token.ts b/src/store/token.ts index 126967b..1425f23 100644 --- a/src/store/token.ts +++ b/src/store/token.ts @@ -105,7 +105,7 @@ export const useTokenStore = defineStore( try { const res = await _login(credentials) console.log('普通登录-res: ', res) - await _postLogin(res.data) + await _postLogin(res) uni.showToast({ title: '登录成功', icon: 'success', @@ -133,7 +133,7 @@ export const useTokenStore = defineStore( console.log('微信登录-code: ', code) const res = await _wxLogin(code) console.log('微信登录-res: ', res) - await _postLogin(res.data) + await _postLogin(res) uni.showToast({ title: '登录成功', icon: 'success', @@ -193,7 +193,7 @@ export const useTokenStore = defineStore( const refreshToken = tokenInfo.value.refreshToken const res = await _refreshToken(refreshToken) console.log('刷新token-res: ', res) - setTokenInfo(res.data) + setTokenInfo(res) return res } catch (error) {