From 3f5ba28bd1304b8dd9f9f93b58c8b30321cb7b8e Mon Sep 17 00:00:00 2001 From: Juanma Hidalgo Date: Mon, 11 Mar 2024 16:21:30 +0100 Subject: [PATCH] fix: remove buy with card button for LANDs --- .../BuyNftWithCryptoModal/BuyNftWithCryptoModal.tsx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/webapp/src/components/Modals/BuyWithCryptoModal/BuyNftWithCryptoModal/BuyNftWithCryptoModal.tsx b/webapp/src/components/Modals/BuyWithCryptoModal/BuyNftWithCryptoModal/BuyNftWithCryptoModal.tsx index c383c8ec0..c0b1f2d63 100644 --- a/webapp/src/components/Modals/BuyWithCryptoModal/BuyNftWithCryptoModal/BuyNftWithCryptoModal.tsx +++ b/webapp/src/components/Modals/BuyWithCryptoModal/BuyNftWithCryptoModal/BuyNftWithCryptoModal.tsx @@ -1,5 +1,5 @@ import React, { useCallback } from 'react' -import { Contract } from '@dcl/schemas' +import { Contract, NFTCategory } from '@dcl/schemas' import { ContractName } from 'decentraland-transactions' import withAuthorizedAction from 'decentraland-dapps/dist/containers/withAuthorizedAction' import { getAnalytics } from 'decentraland-dapps/dist/modules/analytics' @@ -90,7 +90,12 @@ const BuyNftWithCryptoModalHOC = (props: Props) => { price={order.price} isBuyingAsset={isExecutingOrder || isExecutingOrderCrossChain} onBuyNatively={onBuyNatively} - onBuyWithCard={onBuyWithCard} + onBuyWithCard={ + nft.category === NFTCategory.ESTATE || + nft.category === NFTCategory.PARCEL + ? undefined + : onBuyWithCard + } onBuyCrossChain={onExecuteOrderCrossChain} onGetGasCost={onGetGasCost} isLoadingAuthorization={isLoadingAuthorization}