From 9c1c7720c5f516d27b377936a94c2967ea8cd0d8 Mon Sep 17 00:00:00 2001 From: Sam Atkins Date: Fri, 1 Dec 2023 16:44:35 +0000 Subject: [PATCH] LibWeb: Use serialize_a_url() to serialize `@import url(...)` --- Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp b/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp index 816567c681..0fdde7a71e 100644 --- a/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp +++ b/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp @@ -65,10 +65,7 @@ String CSSImportRule::serialized() const builder.append("@import "sv); // 2. The result of performing serialize a URL on the rule’s location. - // FIXME: Look into the correctness of this serialization - builder.append("url("sv); - builder.append(m_url.to_deprecated_string()); - builder.append(')'); + serialize_a_url(builder, MUST(m_url.to_string())); // FIXME: 3. If the rule’s associated media list is not empty, a single SPACE (U+0020) followed by the result of performing serialize a media query list on the media list.