LibJS: Use String::formatted() for throw_exception() message

This commit is contained in:
Linus Groh 2020-10-04 13:55:20 +01:00 committed by Andreas Kling
parent a27668cbae
commit f9eaac62d9
Notes: sideshowbarker 2024-07-19 02:04:05 +09:00
15 changed files with 64 additions and 64 deletions

View file

@ -148,7 +148,7 @@ Value ScriptFunction::call()
Value ScriptFunction::construct(Function&)
{
if (m_is_arrow_function) {
vm().throw_exception<TypeError>(global_object(), ErrorType::NotAConstructor, m_name.characters());
vm().throw_exception<TypeError>(global_object(), ErrorType::NotAConstructor, m_name);
return {};
}
return call();