pub fn check_with_custom_deny<F, Args, P1, P1Args>(
route: Route,
perm: P1,
handler: F,
deny_handler: fn(HttpRequest) -> HttpResponse,
) -> Routewhere
F: Handler<Args>,
Args: FromRequest + 'static,
P1: Permission<P1Args>,
P1Args: FromRequest + 'static,
F::Output: Responder,👎Deprecated since 2.0.0-beta.1: please use
permission() insteadExpand description
Creates a more flexible route than check, which:
- intercepts requests and validates inputs.
- if permission checks are all true, passes through to handler.
- if any of the permissions is false,
deny_handleris called.