Change error type for RequestParts::try_into_request (#639)

This commit is contained in:
Nylonicious
2022-01-23 18:01:52 +01:00
committed by David Pedersen
parent 9b4232b786
commit 455fc46bf3
3 changed files with 8 additions and 30 deletions
-10
View File
@@ -14,16 +14,6 @@ impl Error {
inner: error.into(),
}
}
pub(crate) fn downcast<T>(self) -> Result<T, Self>
where
T: StdError + 'static,
{
match self.inner.downcast::<T>() {
Ok(t) => Ok(*t),
Err(err) => Err(*err.downcast().unwrap()),
}
}
}
impl fmt::Display for Error {