diff options
author | Steve Klebanoff <steve@0xproject.com> | 2018-10-20 03:28:52 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-20 03:28:52 +0800 |
commit | aeb607d485862fd44f846214d6d98058e30a19d7 (patch) | |
tree | d109b232bd8c94376724c78880c387018af0e2fa /packages/instant/src/containers/selected_asset_amount_input.ts | |
parent | c66e2f6704349df5ed76f3ecf8ac74d677c358c3 (diff) | |
parent | c070142dc02e97a3512cf8db189f5fffc9eb469a (diff) | |
download | dexon-0x-contracts-aeb607d485862fd44f846214d6d98058e30a19d7.tar.gz dexon-0x-contracts-aeb607d485862fd44f846214d6d98058e30a19d7.tar.zst dexon-0x-contracts-aeb607d485862fd44f846214d6d98058e30a19d7.zip |
Merge pull request #1161 from 0xProject/feature/instant/order-details-loading-state
[instant] Order details loading state
Diffstat (limited to 'packages/instant/src/containers/selected_asset_amount_input.ts')
-rw-r--r-- | packages/instant/src/containers/selected_asset_amount_input.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/instant/src/containers/selected_asset_amount_input.ts b/packages/instant/src/containers/selected_asset_amount_input.ts index 0810b093a..e55c8b991 100644 --- a/packages/instant/src/containers/selected_asset_amount_input.ts +++ b/packages/instant/src/containers/selected_asset_amount_input.ts @@ -44,13 +44,13 @@ const updateBuyQuoteAsync = async ( const baseUnitValue = Web3Wrapper.toBaseUnitAmount(assetAmount, zrxDecimals); // mark quote as pending - dispatch(actions.updateBuyQuoteStatePending()); + dispatch(actions.setQuoteRequestStatePending()); let newBuyQuote: BuyQuote | undefined; try { newBuyQuote = await assetBuyer.getBuyQuoteAsync(assetData, baseUnitValue); } catch (error) { - dispatch(actions.updateBuyQuoteStateFailure()); + dispatch(actions.setQuoteRequestStateFailure()); errorUtil.errorFlasher.flashNewError(dispatch, error); return; } @@ -72,11 +72,11 @@ const mapDispatchToProps = ( // invalidate the last buy quote. dispatch(actions.updateLatestBuyQuote(undefined)); // reset our buy state - dispatch(actions.updatebuyOrderState(AsyncProcessState.NONE)); + dispatch(actions.updateBuyOrderState(AsyncProcessState.NONE)); if (!_.isUndefined(value) && !_.isUndefined(assetData)) { // even if it's debounced, give them the illusion it's loading - dispatch(actions.updateBuyQuoteStatePending()); + dispatch(actions.setQuoteRequestStatePending()); // tslint:disable-next-line:no-floating-promises debouncedUpdateBuyQuoteAsync(dispatch, assetData, value); } |