fix: trace errors body

This commit is contained in:
Ruben Fiszel
2022-07-04 22:14:46 +02:00
parent 43cc952a15
commit d092c622c4
+1 -1
View File
@@ -62,7 +62,7 @@ impl IntoResponse for Error {
Self::SqlErr(_) | Self::BadRequest(_) => StatusCode::BAD_REQUEST,
_ => StatusCode::INTERNAL_SERVER_ERROR,
};
tracing::error!("status: {status}, error: {body:?}");
tracing::error!(status = %status, error = %e, kind = "error");
Response::builder().status(status).body(body).unwrap()
}
}