From 0c5189a39ba31f921b7414b45956b0e38ef6eb10 Mon Sep 17 00:00:00 2001 From: Temirkhan Myrzamadi Date: Tue, 31 Dec 2019 01:15:58 +0600 Subject: [PATCH] Add #[must_use] to Handler --- src/dispatching/dispatchers/filter.rs | 2 +- src/dispatching/error_handler.rs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/dispatching/dispatchers/filter.rs b/src/dispatching/dispatchers/filter.rs index 148b2256..5f8d3595 100644 --- a/src/dispatching/dispatchers/filter.rs +++ b/src/dispatching/dispatchers/filter.rs @@ -198,7 +198,7 @@ impl<'a, E2, Eh> FilterDispatcher<'a, E2, Eh> { Ok(upd) => upd, Err(err) => { self.error_handler - .handle_error(ErrorKind::FromUpdater(err)); + .handle_error(ErrorKind::FromUpdater(err)).await; return; } }; diff --git a/src/dispatching/error_handler.rs b/src/dispatching/error_handler.rs index ed3703af..56c5a530 100644 --- a/src/dispatching/error_handler.rs +++ b/src/dispatching/error_handler.rs @@ -5,6 +5,7 @@ use std::{convert::Infallible, fmt::Debug, future::Future, pin::Pin}; /// An asynchronous handler of an error. pub trait ErrorHandler { + #[must_use] fn handle_error<'a>( &'a self, error: E,