diff options
author | Steve Klebanoff <steve.klebanoff@gmail.com> | 2018-10-26 05:48:59 +0800 |
---|---|---|
committer | Steve Klebanoff <steve.klebanoff@gmail.com> | 2018-10-26 05:48:59 +0800 |
commit | 89e59cca28a86763519237ab9c6971600e200b5e (patch) | |
tree | 6737a36f05d21b2dab292199cb81e7bd39fce4c1 /packages/instant/src/components | |
parent | f04eba77736a429bea19a4544cfbabc38069d04d (diff) | |
download | dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.tar dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.tar.gz dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.tar.bz2 dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.tar.lz dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.tar.xz dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.tar.zst dexon-0x-contracts-89e59cca28a86763519237ab9c6971600e200b5e.zip |
cleanup code
Diffstat (limited to 'packages/instant/src/components')
-rw-r--r-- | packages/instant/src/components/buy_button.tsx | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/packages/instant/src/components/buy_button.tsx b/packages/instant/src/components/buy_button.tsx index a7a22e3bc..a70269dde 100644 --- a/packages/instant/src/components/buy_button.tsx +++ b/packages/instant/src/components/buy_button.tsx @@ -49,14 +49,9 @@ export class BuyButton extends React.Component<BuyButtonProps> { } catch (e) { if (e instanceof Error && e.message === AssetBuyerError.SignatureRequestDenied) { this.props.onSignatureDenied(buyQuote, e); - } else { - throw e; + return; } - } - - // Have to let TS know that txHash is definitely defined now - if (!txHash) { - throw new Error('No txHash available'); + throw e; } this.props.onBuyProcessing(buyQuote, txHash); |