diff --git a/src/result/auth_result.rs b/src/result/auth_result.rs index 677053e..90e564e 100644 --- a/src/result/auth_result.rs +++ b/src/result/auth_result.rs @@ -69,10 +69,16 @@ impl From for AuthErrorOrOther { } } +mod private { + use gotham::anyhow; + pub trait Sealed {} + impl> Sealed for E {} +} + impl From for AuthErrorOrOther where // TODO https://gitlab.com/msrd0/gotham-restful/-/issues/20 - F: std::error::Error + Into + F: private::Sealed + Into { fn from(err: F) -> Self { Self::Other(err.into())