feat(event): authenticationFailure
This commit is contained in:
parent
a4dc965c23
commit
306d5d8fc7
@ -63,9 +63,15 @@ export default class Xo extends JsonRpcWebSocketClient {
|
||||
}
|
||||
|
||||
_signIn (credentials) {
|
||||
return super.call('session.signIn', credentials).then((user) => {
|
||||
this._user = user
|
||||
this.emit('authenticated')
|
||||
})
|
||||
return super.call('session.signIn', credentials).then(
|
||||
user => {
|
||||
this._user = user
|
||||
this.emit('authenticated')
|
||||
},
|
||||
error => {
|
||||
this.emit('authenticationFailure', error)
|
||||
throw error
|
||||
}
|
||||
)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user