mirror of
https://github.com/actix/actix-web.git
synced 2024-12-21 23:56:35 +00:00
add Clone impl for FromErr combinator
This commit is contained in:
parent
983223a839
commit
0525da70bf
1 changed files with 13 additions and 0 deletions
|
@ -20,6 +20,19 @@ impl<A: Service, E: From<A::Error>> FromErr<A, E> {
|
|||
}
|
||||
}
|
||||
|
||||
impl<A, E> Clone for FromErr<A, E>
|
||||
where
|
||||
A: Service + Clone,
|
||||
E: From<A::Error>,
|
||||
{
|
||||
fn clone(&self) -> Self {
|
||||
FromErr {
|
||||
service: self.service.clone(),
|
||||
f: PhantomData,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl<A, E> Service for FromErr<A, E>
|
||||
where
|
||||
A: Service,
|
||||
|
|
Loading…
Reference in a new issue