diff --git a/Libraries/LibWeb/SVG/SVGGraphicsElement.h b/Libraries/LibWeb/SVG/SVGGraphicsElement.h index bab0f8a38fc..746669ffe98 100644 --- a/Libraries/LibWeb/SVG/SVGGraphicsElement.h +++ b/Libraries/LibWeb/SVG/SVGGraphicsElement.h @@ -79,19 +79,6 @@ protected: Gfx::AffineTransform m_transform = {}; - template - GC::Ptr try_resolve_url_to(URL::URL const& url) const - { - if (!url.fragment().has_value()) - return {}; - auto node = document().get_element_by_id(*url.fragment()); - if (!node) - return {}; - if (is(*node)) - return static_cast(*node); - return {}; - } - template GC::Ptr try_resolve_url_to(CSS::URL const& url) const { diff --git a/Libraries/LibWeb/SVG/SVGTextPathElement.cpp b/Libraries/LibWeb/SVG/SVGTextPathElement.cpp index 0bacd3c6279..eaa7057c289 100644 --- a/Libraries/LibWeb/SVG/SVGTextPathElement.cpp +++ b/Libraries/LibWeb/SVG/SVGTextPathElement.cpp @@ -24,10 +24,7 @@ GC::Ptr SVGTextPathElement::path_or_shape() const auto href = get_attribute(AttributeNames::href); if (!href.has_value()) return {}; - auto url = document().url().complete_url(*href); - if (!url.has_value()) - return {}; - return try_resolve_url_to(*url); + return try_resolve_url_to(*href); } void SVGTextPathElement::initialize(JS::Realm& realm)