Function warp::filters::cookie::optional[][src]

pub fn optional<T>(
    name: &'static str
) -> impl Filter<Extract = (Option<T>,), Error = Infallible> + Copy where
    T: FromStr + Send + 'static, 

Creates a Filter that looks for an optional cookie by name.

If found, extracts the value of the cookie, otherwise continues the request, extracting None.