Skip to content

Instantly share code, notes, and snippets.

@dancameron
Created August 12, 2019 15:49
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 dancameron/b5c6e237048cbcfb8355415b18a01947 to your computer and use it in GitHub Desktop.
Save dancameron/b5c6e237048cbcfb8355415b18a01947 to your computer and use it in GitHub Desktop.
Prevent Redirection to Invoice after WooCommerce Payment
<?php // don't include this line in your functions.php, since it already starts with it.
remove_action( 'woocommerce_thankyou', array( 'SI_Woo_Payment_Processor', 'redirect_to_invoice_after_payment' ) );
add_filter( 'si_woopay_redirect_back_to_invoice', '__return_false' );
@dancameron
Copy link
Author

This snippet is a customization for Sprout Invoices. A customizable solution that provides a way for you to get paid via your WordPress site. For more information please don't hesitate to reach out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment