mirror of https://github.com/fafhrd91/actix-web
changed long type to use existing type alias
This commit is contained in:
parent
afe3ae5044
commit
39be8c36d4
|
@ -212,14 +212,10 @@ impl<B> ErrorHandlers<B> {
|
||||||
/// Otherwise, fall back on the appropriate default handler.
|
/// Otherwise, fall back on the appropriate default handler.
|
||||||
fn get_handler<'a>(
|
fn get_handler<'a>(
|
||||||
status: &StatusCode,
|
status: &StatusCode,
|
||||||
default_client: Option<
|
default_client: Option<&'a ErrorHandler<B>>,
|
||||||
&'a dyn Fn(ServiceResponse<B>) -> Result<ErrorHandlerResponse<B>>,
|
default_server: Option<&'a ErrorHandler<B>>,
|
||||||
>,
|
|
||||||
default_server: Option<
|
|
||||||
&'a dyn Fn(ServiceResponse<B>) -> Result<ErrorHandlerResponse<B>>,
|
|
||||||
>,
|
|
||||||
handlers: &'a Handlers<B>,
|
handlers: &'a Handlers<B>,
|
||||||
) -> Option<&'a dyn Fn(ServiceResponse<B>) -> Result<ErrorHandlerResponse<B>>> {
|
) -> Option<&'a ErrorHandler<B>> {
|
||||||
handlers
|
handlers
|
||||||
.get(status)
|
.get(status)
|
||||||
.map(|h| h.as_ref())
|
.map(|h| h.as_ref())
|
||||||
|
|
Loading…
Reference in New Issue