LibJS: Preserve the original time zone identifier in Intl.DateTimeFormat

This was missed when updating the Intl.DateTimeFormat constructor to
support Temporal.
This commit is contained in:
Timothy Flynn
2026-03-13 08:23:29 -04:00
committed by Tim Flynn
parent 34d7a8fa69
commit b47e4acc96
Notes: github-actions[bot] 2026-03-13 18:45:00 +00:00
2 changed files with 23 additions and 2 deletions

View File

@@ -207,8 +207,8 @@ ThrowCompletionOr<GC::Ref<DateTimeFormat>> create_date_time_format(VM& vm, Funct
if (!time_zone_identifier_record.has_value())
return vm.throw_completion<RangeError>(ErrorType::OptionIsNotValidValue, time_zone, vm.names.timeZone);
// c. Set timeZone to timeZoneIdentifierRecord.[[PrimaryIdentifier]].
time_zone = time_zone_identifier_record->primary_identifier;
// c. Set timeZone to timeZoneIdentifierRecord.[[Identifier]].
time_zone = time_zone_identifier_record->identifier;
}
// 21. Set dateTimeFormat.[[TimeZone]] to timeZone.