mirror of
https://github.com/flarum/core.git
synced 2025-07-31 05:30:38 +02:00
Type-safe session instantiation
This commit is contained in:
@@ -258,7 +258,7 @@ export default class Application {
|
|||||||
|
|
||||||
this.forum = this.store.getById('forums', '1')!;
|
this.forum = this.store.getById('forums', '1')!;
|
||||||
|
|
||||||
this.session = new Session(this.store.getById('users', String(this.data.session.userId)), this.data.session.csrfToken);
|
this.session = new Session(this.store.getById<User>('users', String(this.data.session.userId)) ?? null, this.data.session.csrfToken);
|
||||||
|
|
||||||
this.mount();
|
this.mount();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user