federated-wordpress-customi.../woocommerce/new_subscription_set_to_needs_provision.php

11 lines
336 B
PHP
Raw Permalink Normal View History

2024-05-02 17:51:32 +00:00
<?php
2024-10-17 20:39:34 +00:00
if( ! defined( 'ABSPATH' ) ){
exit; // Exit if accessed directly.
}
2024-05-02 17:51:32 +00:00
function federated_set_new_subscription_provision_status($subscription){
update_field('provision_status', 'needs_provision', $subscription->ID);
}
add_action('woocommerce_checkout_subscription_created', 'federated_set_new_subscription_provision_status');