Type Alias snowboard::Middleware
source · pub type Middleware = fn(request: Request) -> (Request, Option<Response<'static>>);Expand description
Middleware function. Returns a tuple of the modified request and an optional response.
If the response is not None, the request will be ignored, and the response will be sent.