Skip to content

Commit

Permalink
fix: use '?' instead of 'undefined'
Browse files Browse the repository at this point in the history
  • Loading branch information
Keith-CY committed Sep 22, 2024
1 parent 46cffd9 commit ee18ca0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pages/Transaction/TransactionCell/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ const TransactionCellCapacityAmount = ({ cell }: { cell: Cell }) => {
return <span>{`${parseUDTAmount(amount, udtInfo.decimal)} ${udtInfo.symbol}`}</span>
}

return <span>{`${t('udt.unknown_token')} #${udtInfo.typeHash?.substring(udtInfo.typeHash.length - 4)}`}</span>
return <span>{`${t('udt.unknown_token')} #${udtInfo.typeHash.substring(udtInfo.typeHash.length - 4) ?? '?'}`}</span>
}

return <Capacity capacity={shannonToCkb(cell.capacity)} layout="responsive" />
Expand Down

0 comments on commit ee18ca0

Please sign in to comment.