1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 21:17:44 +00:00

LibWeb: Port DOMException interface from DeprecatedString to String

This commit is contained in:
Shannon Booth 2023-09-06 16:03:01 +12:00 committed by Tim Flynn
parent bcb6851c07
commit 41928c2902
65 changed files with 296 additions and 296 deletions

View file

@ -240,9 +240,9 @@ void DOMTokenList::set_value(String const& value)
WebIDL::ExceptionOr<void> DOMTokenList::validate_token(StringView token) const
{
if (token.is_empty())
return WebIDL::SyntaxError::create(realm(), "Non-empty DOM tokens are not allowed");
return WebIDL::SyntaxError::create(realm(), "Non-empty DOM tokens are not allowed"_fly_string);
if (any_of(token, Infra::is_ascii_whitespace))
return WebIDL::InvalidCharacterError::create(realm(), "DOM tokens containing ASCII whitespace are not allowed");
return WebIDL::InvalidCharacterError::create(realm(), "DOM tokens containing ASCII whitespace are not allowed"_fly_string);
return {};
}