Re-arrange .to_owned() placement to stop clippy from complaining

This commit is contained in:
Joshua Goins 2023-09-24 18:45:34 -04:00
parent fbdea47acd
commit 70bfb11e46

View file

@ -85,10 +85,10 @@ async fn main() {
.unwrap(); .unwrap();
let state_clone = initial_state.clone(); 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( serde_json::to_writer(
&std::fs::File::create("votes.json").unwrap(), &std::fs::File::create("votes.json").unwrap(),
&st.to_owned(), &st,
) )
.expect("TODO: panic message"); .expect("TODO: panic message");
} }