소스 검색

fix falsy currentUser

afc163 7 년 전
부모
커밋
422c720713
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/models/user.js

+ 1 - 1
src/models/user.js

@@ -35,7 +35,7 @@ export default {
     saveCurrentUser(state, action) {
     saveCurrentUser(state, action) {
       return {
       return {
         ...state,
         ...state,
-        currentUser: action.payload,
+        currentUser: action.payload || {},
       };
       };
     },
     },
     changeNotifyCount(state, action) {
     changeNotifyCount(state, action) {