From ae4b1e85e669bc882d158509ef1eda46c6b2a72e Mon Sep 17 00:00:00 2001 From: mat Date: Fri, 30 May 2025 19:36:59 -0800 Subject: fix clippy issues and improve formatting everywhere --- azalea-client/src/plugins/join.rs | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'azalea-client/src/plugins/join.rs') diff --git a/azalea-client/src/plugins/join.rs b/azalea-client/src/plugins/join.rs index e31c64c4..a3447782 100644 --- a/azalea-client/src/plugins/join.rs +++ b/azalea-client/src/plugins/join.rs @@ -96,20 +96,20 @@ pub fn handle_start_join_server_event( debug!("Reusing entity {entity:?} for client"); // check if it's already connected - if let Ok(conn) = connection_query.get(entity) { - if conn.is_alive() { - if let Some(start_join_callback_tx) = &event.start_join_callback_tx { - warn!( - "Received StartJoinServerEvent for {entity:?} but it's already connected. Ignoring the event but replying with Ok." - ); - let _ = start_join_callback_tx.0.send(Ok(entity)); - } else { - warn!( - "Received StartJoinServerEvent for {entity:?} but it's already connected. Ignoring the event." - ); - } - return; + if let Ok(conn) = connection_query.get(entity) + && conn.is_alive() + { + if let Some(start_join_callback_tx) = &event.start_join_callback_tx { + warn!( + "Received StartJoinServerEvent for {entity:?} but it's already connected. Ignoring the event but replying with Ok." + ); + let _ = start_join_callback_tx.0.send(Ok(entity)); + } else { + warn!( + "Received StartJoinServerEvent for {entity:?} but it's already connected. Ignoring the event." + ); } + return; } entity -- cgit v1.2.3