From c04f201e53abb39a69a289923dc4648dcc968d21 Mon Sep 17 00:00:00 2001 From: Rafael Zaleski Date: Sun, 15 Dec 2024 22:47:17 -0300 Subject: [PATCH] Remove console statements --- client/express-checkout/event-handlers.js | 4 ---- client/express-checkout/utils/shortcodeCheckout.js | 11 ----------- 2 files changed, 15 deletions(-) diff --git a/client/express-checkout/event-handlers.js b/client/express-checkout/event-handlers.js index 3f8d24fb9db..a763db40a42 100644 --- a/client/express-checkout/event-handlers.js +++ b/client/express-checkout/event-handlers.js @@ -28,7 +28,6 @@ const onShippingRatesCalculated = ( eventAddress ) => { }; export const shippingAddressChangeHandler = async ( api, event, elements ) => { - console.log( event ); try { const response = await api.expressCheckoutECECalculateShippingOptions( normalizeShippingAddress( event.address ) @@ -49,7 +48,6 @@ export const shippingAddressChangeHandler = async ( api, event, elements ) => { event.reject(); } } catch ( e ) { - console.error( e ); event.reject(); } }; @@ -187,8 +185,6 @@ export const onCancelHandler = () => { const context = getExpressCheckoutData( 'button_context' ); const isBlocks = getExpressCheckoutData( 'has_block' ); - console.log( context, isBlocks ); - if ( ! [ 'cart', 'checkout' ].includes( context ) || ! lastSelectedAddress ) return; diff --git a/client/express-checkout/utils/shortcodeCheckout.js b/client/express-checkout/utils/shortcodeCheckout.js index 20df10a0308..f55cee9f21f 100644 --- a/client/express-checkout/utils/shortcodeCheckout.js +++ b/client/express-checkout/utils/shortcodeCheckout.js @@ -9,7 +9,6 @@ import { normalizeShippingAddress, getExpressCheckoutData } from './'; export const updateBlocksShippingUI = ( eventAddress ) => { - console.log( 'updateBlocksShippingUI' ); const address = normalizeShippingAddress( eventAddress ); wp.data.dispatch( 'wc/store/cart' ).setShippingAddress( address ); @@ -33,11 +32,6 @@ export const updateShortcodeShippingUI = ( eventAddress ) => { } else { field.dispatchEvent( new Event( 'change' ) ); } - } else { - console.error( - `form.woocommerce-shipping-calculator [name="calc_shipping_${ key }"]` - ); - console.error( address[ key ] ); } } ); document @@ -59,11 +53,6 @@ export const updateShortcodeShippingUI = ( eventAddress ) => { } else { field.dispatchEvent( new Event( 'change' ) ); } - } else { - console.error( - `form.woocommerce-checkout [name="billing_${ key }"]` - ); - console.error( address[ key ] ); } } ); }