Fix crash after login
This commit is contained in:
parent
d157dc0ee6
commit
eb8b6df527
1 changed files with 4 additions and 1 deletions
|
@ -162,6 +162,8 @@ fn logged_in(model: Model, token: String, session: login_token.Session) {
|
||||||
device: auth_models.Device(name: model.login_view.device_name),
|
device: auth_models.Device(name: model.login_view.device_name),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
let #(m, e) = authed_view.init(auth_data)
|
||||||
|
|
||||||
case
|
case
|
||||||
auth_storage.write(
|
auth_storage.write(
|
||||||
model.auth_storage,
|
model.auth_storage,
|
||||||
|
@ -180,7 +182,8 @@ fn logged_in(model: Model, token: String, session: login_token.Session) {
|
||||||
..model,
|
..model,
|
||||||
auth_data: option.Some(auth_data),
|
auth_data: option.Some(auth_data),
|
||||||
current_view: view.AuthedView,
|
current_view: view.AuthedView,
|
||||||
|
authed_view: option.Some(m),
|
||||||
),
|
),
|
||||||
effect.none(),
|
effect.map(e, AuthedView),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue