aboutsummaryrefslogtreecommitdiffstats
path: root/packages/instant/src/util/buy_quote_updater.ts
diff options
context:
space:
mode:
authorSteve Klebanoff <steve.klebanoff@gmail.com>2018-11-29 06:11:53 +0800
committerSteve Klebanoff <steve.klebanoff@gmail.com>2018-11-29 06:11:53 +0800
commitec01893e9c987fcbd3fd7bcb4ec34498a6f516cc (patch)
treeaf7714c79643c1bbf51a2c8ac19277205ef4e310 /packages/instant/src/util/buy_quote_updater.ts
parentf4cc14f43862c639d2cf9f6e5359e4822f1bcacf (diff)
downloaddexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.tar
dexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.tar.gz
dexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.tar.bz2
dexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.tar.lz
dexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.tar.xz
dexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.tar.zst
dexon-0x-contracts-ec01893e9c987fcbd3fd7bcb4ec34498a6f516cc.zip
fetchedVia -> fetchOrigin
Diffstat (limited to 'packages/instant/src/util/buy_quote_updater.ts')
-rw-r--r--packages/instant/src/util/buy_quote_updater.ts10
1 files changed, 7 insertions, 3 deletions
diff --git a/packages/instant/src/util/buy_quote_updater.ts b/packages/instant/src/util/buy_quote_updater.ts
index 14af57660..06474b69f 100644
--- a/packages/instant/src/util/buy_quote_updater.ts
+++ b/packages/instant/src/util/buy_quote_updater.ts
@@ -20,7 +20,7 @@ export const buyQuoteUpdater = {
options: {
setPending: boolean;
dispatchErrors: boolean;
- fetchedVia: QuoteFetchOrigin;
+ fetchOrigin: QuoteFetchOrigin;
affiliateInfo?: AffiliateInfo;
},
): Promise<void> => {
@@ -37,7 +37,11 @@ export const buyQuoteUpdater = {
} catch (error) {
if (options.dispatchErrors) {
dispatch(actions.setQuoteRequestStateFailure());
- analytics.trackQuoteError(error.message ? error.message : 'other', assetUnitAmount, options.fetchedVia);
+ analytics.trackQuoteError(
+ error.message ? error.message : 'other',
+ assetUnitAmount,
+ options.fetchOrigin,
+ );
let errorMessage;
if (error.message === AssetBuyerError.InsufficientAssetLiquidity) {
const assetName = assetUtils.bestNameForAsset(asset, 'of this asset');
@@ -65,6 +69,6 @@ export const buyQuoteUpdater = {
errorFlasher.clearError(dispatch);
// invalidate the last buy quote.
dispatch(actions.updateLatestBuyQuote(newBuyQuote));
- analytics.trackQuoteFetched(newBuyQuote, options.fetchedVia);
+ analytics.trackQuoteFetched(newBuyQuote, options.fetchOrigin);
},
};