Почему это НЕ РАБОТАЕТ И НЕ ОК:
async login ({ dispatch, state }, user) {
const token = await this.$fireAuth.currentUser.getIdToken(true)
const userInfo = user
Cookies.set('access_token', token) // saving token in cookie for server rendering
await dispatch('setUSER', userInfo)
await dispatch('saveUID', userInfo.uid)
},
, но это ОК И РАБОТАЕТ:
async login ({ dispatch, state }, user) {
const token = await this.$fireAuth.currentUser.getIdToken(true)
const userInfo = {
displayName: "Nicl",
email: user.email,
avatar: user.photoURL,
uid: user.uid,
emailVerified: user.emailVerified
}
Cookies.set('access_token', token) // saving token in cookie for server rendering
await dispatch('setUSER', userInfo)
await dispatch('saveUID', userInfo.uid)
},
Я не понимаю, почему я получаю ошибку, которая кажется случайнойдля меня?