Updated derive more to v1. Removed thiserror
This commit is contained in:
@@ -1,23 +1,23 @@
|
||||
use std::fmt::{Debug, Display};
|
||||
use tracing_subscriber::{fmt, prelude::*, EnvFilter};
|
||||
|
||||
#[derive(thiserror::Error, Debug)]
|
||||
#[error("No user info found")]
|
||||
#[derive(derive_more::Error, derive_more::Display, Debug)]
|
||||
#[display("No user info found")]
|
||||
pub struct NoUserInfo;
|
||||
|
||||
#[derive(thiserror::Error, Debug)]
|
||||
#[error("Handler was already used")]
|
||||
#[derive(derive_more::Error, derive_more::Display, Debug)]
|
||||
#[display("Handler was already used")]
|
||||
pub struct HandlerUsed;
|
||||
|
||||
#[derive(thiserror::Error, Debug)]
|
||||
#[derive(derive_more::Error, derive_more::Display, derive_more::From, Debug)]
|
||||
pub enum InvalidCommand {
|
||||
#[error("Invalid params")]
|
||||
#[display("Invalid params")]
|
||||
InvalidParams,
|
||||
#[error("Not enough bytes in the name's hash")]
|
||||
#[display("Not enough bytes in the name's hash")]
|
||||
InvalidOutputLength,
|
||||
#[error("Error decoding the values: {0}")]
|
||||
NameDecodingError(#[from] base64::DecodeError),
|
||||
#[error("Unknown locale passed into callback")]
|
||||
#[display("Error decoding the values: {}", 0)]
|
||||
NameDecodingError(base64::DecodeError),
|
||||
#[display("Unknown locale passed into callback")]
|
||||
UnknownLocale,
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user