def cookie.path_match

bend-kit-http@0.38.2.0 · http.bend:1939

import bend-kit-http@0.38.2.0/http.bend as Http
import Base

1939# §5.1.4: request path p path-matches cookie path c.
1940def cookie.path_match(+p: String, +c: String) -> Bool:
1941  Bool.or(String.eq(p, c), Bool.and(String.starts_with(p, c), Bool.or(String.ends_with(c, "/"), String.starts_with(String.drop(p, String.length(c)), "/"))))

Uses (9)

Used by (2)