️ Use of the token returned by the first sync with the homeserver

This commit is contained in:
2024-01-01 21:32:32 +01:00
parent 5fe13335a1
commit a8d343ce3a
2 changed files with 13 additions and 9 deletions

View File

@@ -212,8 +212,9 @@ pub async fn login(
if homeserver_url.is_some() && username.is_some() && password.is_some() {
let client = Client::spawn(homeserver_url.unwrap()).await;
// TODO: Handle error case.
let _ = client.init().await;
if let Err(err) = client.init().await {
error!("Following error occureds during client init: {}", err);
}
match client
.login(LoginStyle::Password(username.unwrap(), password.unwrap()))