Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save maxrice/cdd248d9bd982af4ba0c58ba7993efed to your computer and use it in GitHub Desktop.
Save maxrice/cdd248d9bd982af4ba0c58ba7993efed to your computer and use it in GitHub Desktop.
Jilt for WooCommerce - prevent pending orders placed with a certain payment gateway from being sent recovery emails
<?php
add_filter( 'wc_jilt_order_is_placed', function( $placed, $order ) {
return $placed || ( 'pending' == $order->get_status() && 'divido' == $order->get_payment_method() );
}, 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment