Skip to main content

try_validated

Function try_validated 

Source
pub fn try_validated<T: Clone + Send + Sync + 'static>(
    req: &Request<impl Body>,
) -> Option<T>
Expand description

Try to extract the validated value from request extensions.

Returns None if the middleware was not applied or the value type doesn’t match.