Created
February 5, 2015 14:11
-
-
Save barrykooij/a6be308dbc4b559d6da7 to your computer and use it in GitHub Desktop.
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( 'wc_anti_fraud_rules', 'wc_remove_antifraud_rules'); | |
/** | |
* Remove unwanted anti-fraud rules | |
* | |
* @return array | |
*/ | |
function wc_remove_antifraud_rules( $rules ) { | |
foreach ( $rules as $key => $rule ) { | |
if ( 'billing_matches_shipping' === $rule->get_id() ) { | |
unset( $rules[$key] ); | |
} | |
} | |
return $rules; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How do I add multiple rules into this snippet?