mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 08:54:58 +00:00
js: Remove DeprecatedString usage in load_json_impl()
This commit is contained in:
parent
ff5a8a21e8
commit
cb3216cb45
1 changed files with 1 additions and 1 deletions
|
@ -352,7 +352,7 @@ static JS::ThrowCompletionOr<JS::Value> load_ini_impl(JS::VM& vm)
|
|||
|
||||
static JS::ThrowCompletionOr<JS::Value> load_json_impl(JS::VM& vm)
|
||||
{
|
||||
auto filename = TRY(vm.argument(0).to_deprecated_string(vm));
|
||||
auto filename = TRY(vm.argument(0).to_string(vm));
|
||||
auto file_or_error = Core::Stream::File::open(filename, Core::Stream::OpenMode::Read);
|
||||
if (file_or_error.is_error())
|
||||
return vm.throw_completion<JS::Error>(DeprecatedString::formatted("Failed to open '{}': {}", filename, file_or_error.error()));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue