From 8d8534e44320ac5247b59265104e02e8ccf01fa3 Mon Sep 17 00:00:00 2001 From: Bran <52735957+brancoder@users.noreply.github.com> Date: Thu, 26 Dec 2024 18:20:23 +0100 Subject: [PATCH] fix(explorer): improve tx timestamp on homepage (#4603) --- .../src/lib/ui/utils/generateTransactionsTableColumns.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/explorer/src/lib/ui/utils/generateTransactionsTableColumns.tsx b/apps/explorer/src/lib/ui/utils/generateTransactionsTableColumns.tsx index 3cc12a45e2a..ace65b6ba98 100644 --- a/apps/explorer/src/lib/ui/utils/generateTransactionsTableColumns.tsx +++ b/apps/explorer/src/lib/ui/utils/generateTransactionsTableColumns.tsx @@ -89,11 +89,12 @@ export function generateTransactionsTableColumns(): ColumnDef { const timestampMs = getValue(); + const elapsedTime = timestampMs + ? getElapsedTime(Number(timestampMs), Date.now()) + : '--'; return ( - - {getElapsedTime(Number(timestampMs), Date.now()) || '--'} - + {elapsedTime} ); },