muxi feng commited on
Commit
446027a
·
1 Parent(s): 6fa5e4b

修复符号错误

Browse files
Files changed (1) hide show
  1. app/store/user.ts +2 -2
app/store/user.ts CHANGED
@@ -126,7 +126,7 @@ export const useUserStore = create<UserStore>()(
126
  });
127
  let response = await res.json() as shuixianRes
128
  console.log(response)
129
- if(response.code=1){
130
  useUserStore.getState().updateUser(user)
131
  useUserStore.getState().updatePassword(password)
132
  useAccessStore.getState().updateAuth(response.token)
@@ -145,7 +145,7 @@ export const useUserStore = create<UserStore>()(
145
  });
146
  let response = await res.json() as shuixianRes
147
  console.log(response)
148
- if(response.code=1){
149
  showToast(response.msg)
150
  setTimeout(()=>{
151
  window.location.href="/#/login"
 
126
  });
127
  let response = await res.json() as shuixianRes
128
  console.log(response)
129
+ if(response.code==1){
130
  useUserStore.getState().updateUser(user)
131
  useUserStore.getState().updatePassword(password)
132
  useAccessStore.getState().updateAuth(response.token)
 
145
  });
146
  let response = await res.json() as shuixianRes
147
  console.log(response)
148
+ if(response.code==1){
149
  showToast(response.msg)
150
  setTimeout(()=>{
151
  window.location.href="/#/login"