summaryrefslogtreecommitdiff
path: root/webapp/src/components/app_context_provider.rs
diff options
context:
space:
mode:
authorKjetil Orbekk <kj@orbekk.com>2022-11-15 15:14:48 -0500
committerKjetil Orbekk <kj@orbekk.com>2022-11-15 15:15:06 -0500
commit87ede1e2b367a997440626ad9f583600d7cc42fc (patch)
treea3fd0008714e6d524c2e3b967734a0cfb6cf6cbd /webapp/src/components/app_context_provider.rs
parent1f623cca3ea0937508b8c50f4c32a0972271e8f4 (diff)
Fix rust warnings
Diffstat (limited to 'webapp/src/components/app_context_provider.rs')
-rw-r--r--webapp/src/components/app_context_provider.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/webapp/src/components/app_context_provider.rs b/webapp/src/components/app_context_provider.rs
index 0b490fc..bba7e33 100644
--- a/webapp/src/components/app_context_provider.rs
+++ b/webapp/src/components/app_context_provider.rs
@@ -4,7 +4,7 @@ use gloo_net::http::Request;
use log::info;
use protocol::UserInfo;
use uuid::Uuid;
-use std::{future::Future, rc::Rc};
+use std::future::Future;
use wasm_bindgen_futures::spawn_local;
use yew::prelude::*;
use yew_router::prelude::*;
@@ -110,7 +110,7 @@ pub fn use_app_context() -> AppContext {
let state : AppState = use_context::<AppState>().unwrap();
let history = use_history().unwrap();
- AppContext { state: state, history }
+ AppContext { state, history }
}
#[function_component(AppContextProvider)]
@@ -127,7 +127,7 @@ pub fn app_context_provider(props: &Props) -> Html {
match initialize_user_info().await {
Ok(user_info) => user.set(Some(user_info)),
Err(e) => error.set(Some(ErrorInfoProperties {
- message: format!("Could not contact server"),
+ message: format!("Could not contact server: {:?}", e),
})),
};
});