Improve session management
This commit is contained in:
@@ -89,6 +89,7 @@ export class SessionModel {
|
|||||||
|
|
||||||
clear() {
|
clear() {
|
||||||
this.data = null
|
this.data = null
|
||||||
|
this.setOnline(false)
|
||||||
}
|
}
|
||||||
|
|
||||||
setState(data: SessionData) {
|
setState(data: SessionData) {
|
||||||
@@ -201,6 +202,7 @@ export class SessionModel {
|
|||||||
did: res.data.did,
|
did: res.data.did,
|
||||||
})
|
})
|
||||||
this.configureApi()
|
this.configureApi()
|
||||||
|
this.setOnline(true, false)
|
||||||
this.rootStore.me.load().catch(e => {
|
this.rootStore.me.load().catch(e => {
|
||||||
console.error('Failed to fetch local user information', e)
|
console.error('Failed to fetch local user information', e)
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user