diff --git a/Libraries/LibWeb/HTML/HTMLLinkElement.cpp b/Libraries/LibWeb/HTML/HTMLLinkElement.cpp index 3498742015e..867884288e0 100644 --- a/Libraries/LibWeb/HTML/HTMLLinkElement.cpp +++ b/Libraries/LibWeb/HTML/HTMLLinkElement.cpp @@ -772,6 +772,9 @@ void HTMLLinkElement::process_icon_resource(bool success, Fetch::Infrastructure: // https://html.spec.whatwg.org/multipage/links.html#link-type-stylesheet:process-the-linked-resource void HTMLLinkElement::process_stylesheet_resource(bool success, Fetch::Infrastructure::Response const& response, ByteBuffer body_bytes) { + if (!document().is_fully_active()) + return; + // 1. If the resource's Content-Type metadata is not text/css, then set success to false. auto mime_type_string = m_mime_type; Optional mime_type_charset;