From 3d9c75e1970df5e4ed3a00234a1222fab4b8c4e2 Mon Sep 17 00:00:00 2001 From: Adam Yost <2327198+localyost3000@users.noreply.github.com> Date: Thu, 20 Nov 2025 10:59:46 -0700 Subject: [PATCH] looser undefined value comparison Explicit `=== null` does not handle when value is `undefined`. using a loose equal (`==`) covers both null and undefined cases, preventing errors in invalid datetimes Signed-off-by: Adam Yost <2327198+localyost3000@users.noreply.github.com> --- packages/x-date-pickers/src/AdapterLuxon/AdapterLuxon.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/x-date-pickers/src/AdapterLuxon/AdapterLuxon.ts b/packages/x-date-pickers/src/AdapterLuxon/AdapterLuxon.ts index 04dad1132b217..abebdc22bb3ad 100644 --- a/packages/x-date-pickers/src/AdapterLuxon/AdapterLuxon.ts +++ b/packages/x-date-pickers/src/AdapterLuxon/AdapterLuxon.ts @@ -246,7 +246,7 @@ export class AdapterLuxon implements MuiPickersAdapter { }; public isValid = (value: DateTime | null): value is DateTime => { - if (value === null) { + if (value == null) { return false; }