1
0
mirror of https://github.com/actix/actix-extras.git synced 2025-02-02 02:53:10 +01:00

Changed to Box<dyn Future<>> to remove warning

This commit is contained in:
Kurian Thampy 2019-10-01 13:58:06 +05:30 committed by GitHub
parent 8f7f190783
commit 62e9d32b3e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -125,7 +125,7 @@ where
{
type Config = ProtoBufConfig;
type Error = Error;
type Future = Box<Future<Item = Self, Error = Error>>;
type Future = Box<dyn Future<Item = Self, Error = Error>>;
#[inline]
fn from_request(req: &HttpRequest, payload: &mut Payload) -> Self::Future {
@ -164,7 +164,7 @@ pub struct ProtoBufMessage<T: Message + Default> {
length: Option<usize>,
stream: Option<Payload>,
err: Option<ProtoBufPayloadError>,
fut: Option<Box<Future<Item = T, Error = ProtoBufPayloadError>>>,
fut: Option<Box<dyn Future<Item = T, Error = ProtoBufPayloadError>>>,
}
impl<T: Message + Default> ProtoBufMessage<T> {