Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Balakrishnan-flycart/488c1135c35c6a2f085a565d88f61366 to your computer and use it in GitHub Desktop.
Save Balakrishnan-flycart/488c1135c35c6a2f085a565d88f61366 to your computer and use it in GitHub Desktop.
Woo Discount Rules v2 - Subtotal condition compatible for Price Based on Country for WooCommerce by Oscar Gare
add_filter('advanced_woo_discount_rules_converted_currency_value', function($price) {
if(is_numeric($price) && !empty($price)) {
if(function_exists('wcpbc_the_zone')){
if(wcpbc_the_zone()){
$price = wcpbc_the_zone()->get_exchange_rate_price( $price, true, 'generic', '' );
}
}
}
return $price;
}, 10);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment