diff options
author | Fabio Berger <me@fabioberger.com> | 2017-12-21 01:36:12 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2017-12-21 01:36:12 +0800 |
commit | 42b3a7c9d756dd2c68256707c0c96a95370329bd (patch) | |
tree | 11d66908433095940a8f8854c593d96585695851 /packages/website/ts/components/eth_weth_conversion_button.tsx | |
parent | 33315046cdca3816a9ce1ae281d0bae5600a5cc5 (diff) | |
download | dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.tar dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.tar.gz dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.tar.bz2 dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.tar.lz dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.tar.xz dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.tar.zst dexon-0x-contracts-42b3a7c9d756dd2c68256707c0c96a95370329bd.zip |
Move call to error reporter to end of handler so that even if reporting the error takes a while, it doesn't block the UI
Diffstat (limited to 'packages/website/ts/components/eth_weth_conversion_button.tsx')
-rw-r--r-- | packages/website/ts/components/eth_weth_conversion_button.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/website/ts/components/eth_weth_conversion_button.tsx b/packages/website/ts/components/eth_weth_conversion_button.tsx index e802b8782..f45b72d9b 100644 --- a/packages/website/ts/components/eth_weth_conversion_button.tsx +++ b/packages/website/ts/components/eth_weth_conversion_button.tsx @@ -109,11 +109,11 @@ export class EthWethConversionButton extends } else if (!_.includes(errMsg, 'User denied transaction')) { utils.consoleLog(`Unexpected error encountered: ${err}`); utils.consoleLog(err.stack); - await errorReporter.reportAsync(err); const errorMsg = direction === Side.Deposit ? 'Failed to wrap your ETH. Please try again.' : 'Failed to unwrap your WETH. Please try again.'; this.props.dispatcher.showFlashMessage(errorMsg); + await errorReporter.reportAsync(err); } } this.setState({ |