import store from "../store/index.js"
export default function() {
  if (store.state.user.userInfo.nickName === undefined) {
    uni.navigateTo({
      url: "/pages/authen/identity"
    })
    return false
  }
  if (store.state.user.phoneNumber === '' || store.state.user.openId === '' || store.state.user.unionId === '') {
    uni.navigateTo({
      url: "/pages/authen/login"
    })
    return false
  }
  return true
}
