mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 11:37:44 +00:00
LibJS: Port to_temporal_offset() to String
This commit is contained in:
parent
3aa3ab65b1
commit
a387b22599
4 changed files with 9 additions and 9 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2021-2022, Linus Groh <linusg@serenityos.org>
|
||||
* Copyright (c) 2021-2023, Linus Groh <linusg@serenityos.org>
|
||||
* Copyright (c) 2021, Luke Wilde <lukew@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
|
@ -88,7 +88,7 @@ JS_DEFINE_NATIVE_FUNCTION(ZonedDateTimeConstructor::from)
|
|||
(void)TRY(to_temporal_disambiguation(vm, options));
|
||||
|
||||
// c. Perform ? ToTemporalOffset(options, "reject").
|
||||
(void)TRY(to_temporal_offset(vm, options, "reject"));
|
||||
(void)TRY(to_temporal_offset(vm, options, "reject"sv));
|
||||
|
||||
// d. Return ! CreateTemporalZonedDateTime(item.[[Nanoseconds]], item.[[TimeZone]], item.[[Calendar]]).
|
||||
return MUST(create_temporal_zoned_date_time(vm, item_object.nanoseconds(), item_object.time_zone(), item_object.calendar()));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue