Skip to content

Commit

Permalink
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/frontend/src/utils/format.ts
Original file line number Diff line number Diff line change
@@ -124,6 +124,9 @@ export function truncateHash(hash) {
}

export function formatTokenString(value: BigNumber, tokenDecimals = 18, trailingDecimals = 2) {
if (value == null || tokenDecimals == null) {
return ''
}
if (tokenDecimals <= 1) {
return value.toString()
}

0 comments on commit afcc73c

Please sign in to comment.