Skip to main content

rustauth_core/utils/
fetch_metadata.rs

1/// Returns true for browser fetch requests with `Sec-Fetch-Mode: cors`.
2pub fn is_browser_fetch_request(sec_fetch_mode: Option<&str>) -> bool {
3    sec_fetch_mode.is_some_and(|mode| mode.eq_ignore_ascii_case("cors"))
4}