Skip to content

Commit

Permalink
fix: getCurrencyString Exception
Browse files Browse the repository at this point in the history
  • Loading branch information
j7-dev committed Oct 12, 2024
1 parent 6d4f12a commit ff29f03
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/src/utils/functions/common.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export const getCurrencyString = ({
price: number | string | undefined
symbol?: string
}) => {
if (typeof price === 'undefined' || price === null) return ''
if (!price && price !== 0 && price !== '0') return ''
if (typeof price === 'string') return `${symbol} ${price}`
return `${symbol} ${price.toString()}`
}
Expand Down

0 comments on commit ff29f03

Please sign in to comment.