tweak various log levels and messages
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
33cc3d56c1
commit
541fa2d2f7
4 changed files with 32 additions and 41 deletions
|
@ -9,7 +9,7 @@ use ruma::{
|
|||
OwnedServerName,
|
||||
};
|
||||
use thiserror::Error;
|
||||
use tracing::{error, info};
|
||||
use tracing::{debug, error};
|
||||
use ErrorKind::{
|
||||
Forbidden, GuestAccessForbidden, LimitExceeded, MissingToken, NotFound, ThreepidAuthFailed, ThreepidDenied,
|
||||
TooLarge, Unauthorized, Unknown, UnknownToken, Unrecognized, UserDeactivated, WrongRoomKeysVersion,
|
||||
|
@ -110,7 +110,6 @@ impl Error {
|
|||
}
|
||||
|
||||
let message = format!("{self}");
|
||||
|
||||
let (kind, status_code) = match self {
|
||||
Self::BadRequest(kind, _) => (
|
||||
kind.clone(),
|
||||
|
@ -142,8 +141,7 @@ impl Error {
|
|||
_ => (Unknown, StatusCode::INTERNAL_SERVER_ERROR),
|
||||
};
|
||||
|
||||
info!("Returning an error: {status_code}: {message}");
|
||||
|
||||
debug!("Returning an error: {status_code}: {message}");
|
||||
RumaResponse(UiaaResponse::MatrixError(RumaError {
|
||||
body: ErrorBody::Standard {
|
||||
kind,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue