mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 14:38:11 +00:00
LibJS: Use String::formatted() in various other places
This commit is contained in:
parent
2e2571743b
commit
123f98201e
7 changed files with 23 additions and 22 deletions
|
@ -747,7 +747,7 @@ bool Object::define_native_function(const StringOrSymbol& property_name, AK::Fun
|
|||
if (property_name.is_string()) {
|
||||
function_name = property_name.as_string();
|
||||
} else {
|
||||
function_name = String::format("[%s]", property_name.as_symbol()->description().characters());
|
||||
function_name = String::formatted("[{}]", property_name.as_symbol()->description());
|
||||
}
|
||||
auto* function = NativeFunction::create(global_object(), function_name, move(native_function));
|
||||
function->define_property("length", Value(length), Attribute::Configurable);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue