1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:27:45 +00:00

Everywhere: Rename JS::PropertyKey variables from property_{name => key}

PropertyKey used to be called PropertyName, but got renamed. Let's
update all the variables of this type as well.
This commit is contained in:
Linus Groh 2022-02-06 15:59:04 +00:00
parent 3e6aaa3520
commit 6f20f49b21
25 changed files with 435 additions and 435 deletions

View file

@ -225,13 +225,13 @@ struct Traits<JS::PropertyKey> : public GenericTraits<JS::PropertyKey> {
template<>
struct Formatter<JS::PropertyKey> : Formatter<StringView> {
ErrorOr<void> format(FormatBuilder& builder, JS::PropertyKey const& property_name)
ErrorOr<void> format(FormatBuilder& builder, JS::PropertyKey const& property_key)
{
if (!property_name.is_valid())
if (!property_key.is_valid())
return Formatter<StringView>::format(builder, "<invalid PropertyKey>");
if (property_name.is_number())
return Formatter<StringView>::format(builder, String::number(property_name.as_number()));
return Formatter<StringView>::format(builder, property_name.to_string_or_symbol().to_display_string());
if (property_key.is_number())
return Formatter<StringView>::format(builder, String::number(property_key.as_number()));
return Formatter<StringView>::format(builder, property_key.to_string_or_symbol().to_display_string());
}
};