1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 09:04:59 +00:00

AK: Port URL scheme from DeprecatedString to String

This commit is contained in:
Shannon Booth 2023-08-12 16:52:41 +12:00 committed by Andrew Kaster
parent 21fe86d235
commit c25485700a
16 changed files with 30 additions and 30 deletions

View file

@ -850,7 +850,7 @@ URL URLParser::basic_parse(StringView raw_input, Optional<URL> const& base_url,
}
// 2. Set urls scheme to buffer.
url->m_scheme = buffer.to_deprecated_string();
url->m_scheme = buffer.to_string().release_value_but_fixme_should_propagate_errors();
// 3. If state override is given, then:
if (state_override.has_value()) {
@ -1281,7 +1281,7 @@ URL URLParser::basic_parse(StringView raw_input, Optional<URL> const& base_url,
// -> file state, https://url.spec.whatwg.org/#file-state
case State::File:
// 1. Set urls scheme to "file".
url->m_scheme = "file";
url->m_scheme = String::from_utf8("file"sv).release_value_but_fixme_should_propagate_errors();
// 2. Set urls host to the empty string.
url->m_host = String {};