You've already forked authentication-service
mirror of
https://github.com/matrix-org/matrix-authentication-service.git
synced 2025-11-20 12:02:22 +03:00
storage: unify user operations errors
This commit is contained in:
@@ -59,13 +59,16 @@ mod views;
|
||||
/// errors.
|
||||
#[macro_export]
|
||||
macro_rules! impl_from_error_for_route {
|
||||
($error:ty) => {
|
||||
impl From<$error> for self::RouteError {
|
||||
($route_error:ty : $error:ty) => {
|
||||
impl From<$error> for $route_error {
|
||||
fn from(e: $error) -> Self {
|
||||
Self::Internal(Box::new(e))
|
||||
}
|
||||
}
|
||||
};
|
||||
($error:ty) => {
|
||||
impl_from_error_for_route!(self::RouteError: $error);
|
||||
};
|
||||
}
|
||||
|
||||
pub use mas_axum_utils::http_client_factory::HttpClientFactory;
|
||||
|
||||
Reference in New Issue
Block a user