From 108c6ea78923233c7d9e8ecf19a275f979ce4123 Mon Sep 17 00:00:00 2001 From: dave Date: Tue, 29 Mar 2022 13:41:07 +0100 Subject: [PATCH 1/3] add userAddress to quoteParamChanged check (#2605) --- src/custom/state/price/updater.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/custom/state/price/updater.ts b/src/custom/state/price/updater.ts index a46c1cbcc..3ef0b5802 100644 --- a/src/custom/state/price/updater.ts +++ b/src/custom/state/price/updater.ts @@ -59,12 +59,15 @@ function quoteUsingSameParameters(currentParams: FeeQuoteParams, quoteInfo: Quot sellToken: currentSellToken, buyToken: currentBuyToken, kind: currentKind, + userAddress: currentUserAddress, } = currentParams - const { amount, buyToken, sellToken, kind } = quoteInfo - - return ( + const { amount, buyToken, sellToken, kind, userAddress } = quoteInfo + // cache the base quote params without quoteInfo user address to check + const paramsWithoutAddress = sellToken === currentSellToken && buyToken === currentBuyToken && amount === currentAmount && kind === currentKind - ) + // 2 checks: if there's a quoteInfo user address (meaning quote was already calculated once) and one without + // in case user is not connected + return userAddress ? currentUserAddress === userAddress && paramsWithoutAddress : paramsWithoutAddress } /** From 05628f7a8f9a83de3b86bbce4bcef9e11e3cd9d8 Mon Sep 17 00:00:00 2001 From: dave Date: Tue, 29 Mar 2022 13:43:00 +0100 Subject: [PATCH 2/3] 2604 - Override cow token image in activities modal (#2606) * override cow token image * use vCowLogo --- src/custom/constants/tokens/index.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/custom/constants/tokens/index.ts b/src/custom/constants/tokens/index.ts index ac857eca7..48f494299 100644 --- a/src/custom/constants/tokens/index.ts +++ b/src/custom/constants/tokens/index.ts @@ -7,7 +7,9 @@ import { SupportedChainId } from 'constants/chains' import { V_COW_CONTRACT_ADDRESS, COW_CONTRACT_ADDRESS } from 'constants/index' import wxDaiLogo from 'assets/cow-swap/wxdai.png' -import vCowLogo from 'assets/cow-swap/cow.svg' +// TODO: these are the same? why? +import vCowLogo from 'assets/cow-swap/vCOW.png' +import cowLogo from 'assets/cow-swap/cow.svg' import gnoLogo from 'assets/cow-swap/gno.png' import usdcLogo from 'assets/cow-swap/usdc.png' @@ -127,6 +129,7 @@ export const ADDRESS_IMAGE_OVERRIDE = { [WBTC_RINKEBY.address]: getTrustImage(WBTC.address), [WETH9[ChainId.RINKEBY].address]: getTrustImage(WETH_ADDRESS_MAINNET), [V_COW_TOKEN_RINKEBY.address]: vCowLogo, + [COW_TOKEN_RINKEBY.address]: cowLogo, [GNO_RINKEBY.address]: gnoLogo, [USDC_RINKEBY.address]: usdcLogo, // xDai @@ -136,8 +139,10 @@ export const ADDRESS_IMAGE_OVERRIDE = { [WXDAI.address]: wxDaiLogo, [WETH_XDAI.address]: getTrustImage(WETH_ADDRESS_MAINNET), [V_COW_TOKEN_XDAI.address]: vCowLogo, + [COW_TOKEN_XDAI.address]: cowLogo, [GNO_XDAI.address]: gnoLogo, [USDC_XDAI.address]: usdcLogo, // Mainnet [V_COW_TOKEN_MAINNET.address]: vCowLogo, + [COW_TOKEN_MAINNET.address]: cowLogo, } From 9fde33bb9cf540492403d8c89b2ea6f66fc2c407 Mon Sep 17 00:00:00 2001 From: w3stside Date: Tue, 29 Mar 2022 16:42:34 +0100 Subject: [PATCH 3/3] push new sentry config --- craco.config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/craco.config.js b/craco.config.js index f52c17285..f6296b3c9 100644 --- a/craco.config.js +++ b/craco.config.js @@ -21,7 +21,7 @@ if (SENTRY_AUTH_TOKEN) { // sentry-cli configuration - can also be done directly through sentry-cli // see https://docs.sentry.io/product/cli/configuration/ for details authToken: SENTRY_AUTH_TOKEN, - org: 'gnosis-protocol', + org: 'cowprotocol', project: 'cowswap', release: SENTRY_RELEASE_VERSION,