We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I try to store my login token but following error prevent storing data & produce following error TypeError: Cannot read property 'data' of undefined
my login.vue is
export default { data(){ return { form:{ email: null, password: null } } }, methods:{ login(){ axios.post('/api/login',this.form) .then(res => User.responseAfterLogin(res)) .catch(error => console.log(error.response.data))
user.js
class User{
responseAfterLogin(res){ const access_token = res.data.access_token const username = res.data.name if (Token.isValid(access_token)) { AppStorage.store(access_token,username) }
can anyone help me on this ?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I try to store my login token but following error prevent storing data & produce following error
TypeError: Cannot read property 'data' of undefined
my login.vue is
export default {
data(){
return {
form:{
email: null,
password: null
}
}
},
methods:{
login(){
axios.post('/api/login',this.form)
.then(res => User.responseAfterLogin(res))
.catch(error => console.log(error.response.data))
user.js
class User{
can anyone help me on this ?
The text was updated successfully, but these errors were encountered: