From 74de7da89ac51ae1d92e52cd2ada62d1fc130265 Mon Sep 17 00:00:00 2001 From: fyears <1142836+fyears@users.noreply.github.com> Date: Sat, 18 May 2024 01:41:54 +0800 Subject: [PATCH] fix timestamp to date using native js --- src/misc.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/misc.ts b/src/misc.ts index 1ff70da..d90d60b 100644 --- a/src/misc.ts +++ b/src/misc.ts @@ -345,7 +345,7 @@ export const unixTimeToStr = (x: number | undefined | null) => { if (x === undefined || x === null || Number.isNaN(x)) { return undefined; } - return window.moment(x).format() as string; + return new Date(x).toISOString(); }; /**