session_handler: don't clone request before tracing
All checks were successful
Build and test / check-license (push) Successful in 58s
Build and test / check (push) Successful in 2m5s
Build and test / build (push) Successful in 3m45s
Build and test / test (push) Successful in 3m28s
Build and test / docs (push) Successful in 6m43s

This commit is contained in:
2026-01-03 23:04:04 +09:00
parent b9f11d0413
commit cb4b8a78dc

View File

@@ -173,18 +173,13 @@ async fn session_handler_with_db_connection(
}
};
// TODO: don't clone the request
let request_to_display = match &request {
Request::PasswdUser((db_user, _)) => {
match &request {
Request::Exit => tracing::debug!("Received request: {:#?}", request),
Request::PasswdUser((db_user, _)) => tracing::info!(
"Received request: {:#?}",
Request::PasswdUser((db_user.to_owned(), "<REDACTED>".to_string()))
}
request => request.to_owned(),
};
if request_to_display == Request::Exit {
tracing::debug!("Received request: {:#?}", request_to_display);
} else {
tracing::info!("Received request: {:#?}", request_to_display);
),
request => tracing::info!("Received request: {:#?}", request),
}
let response = match request {