diff --git a/Userland/Libraries/LibJS/Runtime/Temporal/PlainDateTimePrototype.cpp b/Userland/Libraries/LibJS/Runtime/Temporal/PlainDateTimePrototype.cpp index 22cae0abd9..a7cfb735e7 100644 --- a/Userland/Libraries/LibJS/Runtime/Temporal/PlainDateTimePrototype.cpp +++ b/Userland/Libraries/LibJS/Runtime/Temporal/PlainDateTimePrototype.cpp @@ -59,7 +59,7 @@ void PlainDateTimePrototype::initialize(Realm& realm) u8 attr = Attribute::Writable | Attribute::Configurable; define_native_function(realm, vm.names.with, with, 1, attr); - define_native_function(realm, vm.names.withPlainTime, with_plain_time, 1, attr); + define_native_function(realm, vm.names.withPlainTime, with_plain_time, 0, attr); define_native_function(realm, vm.names.withPlainDate, with_plain_date, 1, attr); define_native_function(realm, vm.names.withCalendar, with_calendar, 1, attr); define_native_function(realm, vm.names.add, add, 1, attr); diff --git a/Userland/Libraries/LibJS/Tests/builtins/Temporal/PlainDateTime/PlainDateTime.prototype.withPlainTime.js b/Userland/Libraries/LibJS/Tests/builtins/Temporal/PlainDateTime/PlainDateTime.prototype.withPlainTime.js index 6d5ba6376f..e32f675d29 100644 --- a/Userland/Libraries/LibJS/Tests/builtins/Temporal/PlainDateTime/PlainDateTime.prototype.withPlainTime.js +++ b/Userland/Libraries/LibJS/Tests/builtins/Temporal/PlainDateTime/PlainDateTime.prototype.withPlainTime.js @@ -1,6 +1,6 @@ describe("correct behavior", () => { - test("length is 1", () => { - expect(Temporal.PlainDateTime.prototype.withPlainTime).toHaveLength(1); + test("length is 0", () => { + expect(Temporal.PlainDateTime.prototype.withPlainTime).toHaveLength(0); }); test("basic functionality", () => {