Last active
May 10, 2018 09:39
-
-
Save malsubrata/89fc741b32adc7fab7d355319465856f to your computer and use it in GitHub Desktop.
Restrict cashback for COD payment method
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
add_filter('process_woo_wallet_general_cashback', 'process_woo_wallet_general_cashback_callback', 10, 2); | |
function woo_wallet_general_cashback_amount($precess, $order){ | |
if('cod' === $order->get_payment_method('edit')){ | |
return false; | |
} | |
return $precess; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment