diff --git a/AK/URL.h b/AK/URL.h index ba546c8057..f229b0d188 100644 --- a/AK/URL.h +++ b/AK/URL.h @@ -79,9 +79,7 @@ public: String serialize(ExcludeFragment = ExcludeFragment::No) const; String serialize_for_display() const; - String to_string() const { return serialize(); } - String to_string_encoded() const { return serialize(); } bool equals(URL const& other, ExcludeFragment = ExcludeFragment::No) const; diff --git a/Userland/Libraries/LibWeb/Loader/ResourceLoader.cpp b/Userland/Libraries/LibWeb/Loader/ResourceLoader.cpp index b02fb31ccd..50c82d7eaf 100644 --- a/Userland/Libraries/LibWeb/Loader/ResourceLoader.cpp +++ b/Userland/Libraries/LibWeb/Loader/ResourceLoader.cpp @@ -156,7 +156,7 @@ void ResourceLoader::load(const LoadRequest& request, Function"); - builder.appendff("The web page {} has crashed.

You can reload the page to try again.", escape_html_entities(m_url.to_string_encoded()), escape_html_entities(m_url.to_string())); + auto escaped_url = escape_html_entities(m_url.to_string()); + builder.appendff("The web page {} has crashed.

You can reload the page to try again.", escaped_url, escaped_url); builder.append(""); load_html(builder.to_string(), m_url); }