Skip to content

Commit

Permalink
OCT-2326 Estimated gas price during withdrawal is zero (#634)
Browse files Browse the repository at this point in the history
  • Loading branch information
aziolek authored Jan 24, 2025
2 parents e67d03c + fffb6e7 commit 53a9f42
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { FC } from 'react';
import { useTranslation } from 'react-i18next';
import { useFeeData } from 'wagmi';
import { useGasPrice } from 'wagmi';

import BoxRounded from 'components/ui/BoxRounded';
import Sections from 'components/ui/BoxRounded/Sections/Sections';
Expand All @@ -17,7 +17,7 @@ const WithdrawEth: FC<WithdrawEthProps> = ({ onCloseModal }) => {
const { i18n, t } = useTranslation('translation', {
keyPrefix: 'components.home.homeGridPersonalAllocation.modalWithdrawEth',
});
const { data: feeData, isFetching: isFetchingFeeData } = useFeeData();
const { data: gasPrice, isFetching: isFetchingGasPrice } = useGasPrice();
const { isAppWaitingForTransactionToBeIndexed, addTransactionPending } = useTransactionLocalStore(
state => ({
addTransactionPending: state.addTransactionPending,
Expand Down Expand Up @@ -66,9 +66,9 @@ const WithdrawEth: FC<WithdrawEthProps> = ({ onCloseModal }) => {
doubleValueProps: {
cryptoCurrency: 'ethereum',
dataTest: 'WithdrawEth__Section--estGasPrice',
isFetching: isFetchingFeeData,
isFetching: isFetchingGasPrice,
showCryptoSuffix: true,
valueCrypto: BigInt(feeData?.gasPrice ?? 0),
valueCrypto: BigInt(gasPrice ?? 0),
},
label: t('estimatedGasPrice'),
},
Expand Down

0 comments on commit 53a9f42

Please sign in to comment.