diff --git a/Userland/Libraries/LibWeb/Fetch/Headers.cpp b/Userland/Libraries/LibWeb/Fetch/Headers.cpp index 6c4091aa10..5628023a01 100644 --- a/Userland/Libraries/LibWeb/Fetch/Headers.cpp +++ b/Userland/Libraries/LibWeb/Fetch/Headers.cpp @@ -154,7 +154,7 @@ WebIDL::ExceptionOr Headers::set(DeprecatedString const& name_string, Depr if (m_guard == Guard::Request && Infrastructure::is_forbidden_header_name(name)) return {}; - // 5. Otherwise, if this’s guard is "request-no-cors" and name/value is not a no-CORS-safelisted request-header, return. + // 5. Otherwise, if this’s guard is "request-no-cors" and (name, value) is not a no-CORS-safelisted request-header, return. if (m_guard == Guard::RequestNoCORS && !Infrastructure::is_no_cors_safelisted_request_header(header)) return {}; @@ -253,7 +253,7 @@ WebIDL::ExceptionOr Headers::append(Infrastructure::Header header) .value = temporary_value.release_value(), }; - // 4. If name/temporaryValue is not a no-CORS-safelisted request-header, then return. + // 4. If (name, temporaryValue) is not a no-CORS-safelisted request-header, then return. if (!Infrastructure::is_no_cors_safelisted_request_header(temporary_header)) return {}; } diff --git a/Userland/Libraries/LibWeb/Fetch/Infrastructure/HTTP/Headers.cpp b/Userland/Libraries/LibWeb/Fetch/Infrastructure/HTTP/Headers.cpp index b457b44598..f54ade2d7a 100644 --- a/Userland/Libraries/LibWeb/Fetch/Infrastructure/HTTP/Headers.cpp +++ b/Userland/Libraries/LibWeb/Fetch/Infrastructure/HTTP/Headers.cpp @@ -569,13 +569,13 @@ bool is_no_cors_safelisted_request_header_name(ReadonlyBytes header_name) // https://fetch.spec.whatwg.org/#no-cors-safelisted-request-header bool is_no_cors_safelisted_request_header(Header const& header) { - // To determine whether a header header is a no-CORS-safelisted request-header, run these steps: + // To determine whether a header (name, value) is a no-CORS-safelisted request-header, run these steps: - // 1. If header’s name is not a no-CORS-safelisted request-header name, then return false. + // 1. If name is not a no-CORS-safelisted request-header name, then return false. if (!is_no_cors_safelisted_request_header_name(header.name)) return false; - // 2. Return whether header is a CORS-safelisted request-header. + // 2. Return whether (name, value) is a CORS-safelisted request-header. return is_cors_safelisted_request_header(header); }