mirror of
https://github.com/flarum/framework.git
synced 2025-05-24 23:59:57 +08:00
Replace Ember app with Mithril app
This commit is contained in:
10
js/lib/initializers/session.js
Normal file
10
js/lib/initializers/session.js
Normal file
@ -0,0 +1,10 @@
|
||||
import Session from 'flarum/session';
|
||||
|
||||
export default function(app) {
|
||||
app.session = new Session();
|
||||
|
||||
if (app.preload.session) {
|
||||
app.session.token(app.preload.session.token);
|
||||
app.session.user(app.store.getById('users', app.preload.session.userId));
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user