1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-11 18:20:43 +09:00

AK: Port URL::m_fragment from DeprecatedString to String

This commit is contained in:
Shannon Booth 2023-08-12 16:52:42 +12:00 committed by Andrew Kaster
parent 5663a2d3b4
commit 9d60f23abc
Notes: sideshowbarker 2024-07-17 03:00:02 +09:00
21 changed files with 68 additions and 76 deletions

View file

@ -87,9 +87,9 @@ JS::GCPtr<SVGGradientElement const> SVGGradientElement::linked_gradient() const
if (auto href = link; !href.is_empty()) {
auto url = document().parse_url(href);
auto id = url.fragment();
if (id.is_empty())
if (!id.has_value() || id->is_empty())
return {};
auto element = document().get_element_by_id(id);
auto element = document().get_element_by_id(id->to_deprecated_string());
if (!element)
return {};
if (!is<SVGGradientElement>(*element))