From 7be2dab9d558a75a9944fec99a33437c5a221a92 Mon Sep 17 00:00:00 2001 From: Xianny <8582774+xianny@users.noreply.github.com> Date: Mon, 10 Dec 2018 15:08:13 -0800 Subject: perform null check on token metadata (#1412) --- packages/pipeline/src/parsers/token_metadata/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/pipeline/src/parsers/token_metadata/index.ts b/packages/pipeline/src/parsers/token_metadata/index.ts index 3b3e05d76..f258af063 100644 --- a/packages/pipeline/src/parsers/token_metadata/index.ts +++ b/packages/pipeline/src/parsers/token_metadata/index.ts @@ -38,7 +38,7 @@ function parseZeroExTrustedToken(resp: ZeroExTrustedTokenMeta): TokenMetadata { const trustedToken = new TokenMetadata(); trustedToken.address = resp.address; - trustedToken.decimals = new BigNumber(resp.decimals); + trustedToken.decimals = resp.decimals ? new BigNumber(resp.decimals) : null; trustedToken.symbol = resp.symbol; trustedToken.name = resp.name; trustedToken.authority = '0x'; -- cgit