初志鑫 4 년 전
부모
커밋
5ae4f4b80b
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      src/store/modules/user.js

+ 2 - 2
src/store/modules/user.js

@@ -68,8 +68,8 @@ const actions = {
       );
     }
   },
-  async getUserInfo({ commit }) {
-    const { data } = await getUserInfo();
+  async getUserInfo({ commit, state }) {
+    const { data } = await getUserInfo(state.accessToken);
     if (!data) {
       Vue.prototype.$baseMessage("验证失败,请重新登录...", "error");
       return false;