Skip to content

Instantly share code, notes, and snippets.

@kreamweb
Created June 29, 2018 09:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kreamweb/477376dcc1a35e42e53a25b62a39723a to your computer and use it in GitHub Desktop.
Save kreamweb/477376dcc1a35e42e53a25b62a39723a to your computer and use it in GitHub Desktop.
Fix to remove the conflict between YITH WooCommerce Request a Quote and WooCommerce Subscription when a request of quote is sent.
<?php
/**
* Fix to remove the conflict between YITH WooCommerce Request a Quote and WooCommerce Subscription
* when a request of quote is sent.
*/
add_action('ywraq_before_create_order', 'ywraq_fix_woocommerce_subscription_conflict');
function ywraq_fix_woocommerce_subscription_conflict(){
remove_filter( 'woocommerce_payment_complete_order_status', 'WC_Subscriptions_Order::maybe_autocomplete_order', 10 );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment