Skip to content

Instantly share code, notes, and snippets.

@danielbitzer
Created July 6, 2018 05:24
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danielbitzer/1b7c9259ea1c8161b1234b3587cc6115 to your computer and use it in GitHub Desktop.
Save danielbitzer/1b7c9259ea1c8161b1234b3587cc6115 to your computer and use it in GitHub Desktop.
[WooCommerce] Add custom order is paid statuses
<?php
add_filter( 'woocommerce_order_is_paid_statuses', 'my_custom_woocommerce_order_is_paid_statuses' );
/**
* @param array $statuses
* @return array
*/
function my_custom_woocommerce_order_is_paid_statuses( $statuses ) {
// already included statuses are processing and completed
$statuses[] = 'my-custom-status';
$statuses[] = 'my-other-custom-status';
return $statuses;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment