diff --git a/src/main.rs b/src/main.rs index 9e689f3..742e8da 100644 --- a/src/main.rs +++ b/src/main.rs @@ -85,10 +85,10 @@ async fn main() { .unwrap(); let state_clone = initial_state.clone(); - let st = state_clone.record.lock().unwrap(); + let st = state_clone.record.lock().unwrap().to_owned(); serde_json::to_writer( &std::fs::File::create("votes.json").unwrap(), - &st.to_owned(), + &st, ) .expect("TODO: panic message"); }