From 6dbedb038a152a22dd9ee4b04a41a8b3ffde5d1f Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 7 Dec 2025 00:51:13 +0000 Subject: Handle null/undefined dates in sorting logic Co-authored-by: jpdillingham <17145758+jpdillingham@users.noreply.github.com> --- src/web/src/components/System/Files/Explorer.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/web') diff --git a/src/web/src/components/System/Files/Explorer.jsx b/src/web/src/components/System/Files/Explorer.jsx index 543c0744..ca0bdba1 100644 --- a/src/web/src/components/System/Files/Explorer.jsx +++ b/src/web/src/components/System/Files/Explorer.jsx @@ -180,8 +180,8 @@ const Explorer = ({ remoteFileManagement, root }) => { sensitivity: 'base', }); } else if (sortColumn === 'date') { - const dateA = new Date(a.modifiedAt); - const dateB = new Date(b.modifiedAt); + const dateA = a.modifiedAt ? new Date(a.modifiedAt) : new Date(0); + const dateB = b.modifiedAt ? new Date(b.modifiedAt) : new Date(0); compareValue = dateA - dateB; } -- cgit v1.2.3