Created
June 9, 2015 18:48
-
-
Save maxrice/366196bce310866499d3 to your computer and use it in GitHub Desktop.
WooCommerce Local Pickup Plus - Remove pickup location action
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function wc_local_pickup_plus_remove_pickup_location() { | |
| $methods = WC()->shipping->load_shipping_methods(); | |
| if ( isset( $methods['local_pickup_plus'] ) ) { | |
| remove_action( 'woocommerce_after_template_part', array( $methods['local_pickup_plus'], 'review_order_shipping_pickup_location' ), 10, 4 ); | |
| } | |
| } | |
| add_action( 'wc_shipping_local_pickup_plus_init', 'wc_local_pickup_plus_remove_pickup_location' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I created a gist that accomplished the functionality that I was looking for. Hope this helps someone else.
https://gist.github.com/artisanpixel/70eb6ad21d105a12741e98f5a4088cbf