Hi @jivedig, aha! The custom workflow is causing this.
I’d suggest you create your own action after the form is saved and hook it into the “Trip sent for review” trigger.
How? Add this after all your custom data handling:
[...]
// Add the hook back
// add_action( 'save_post_trip', array( $this, 'update_trip_post_data' ), 20 );
add_action( 'acf/save_post', array( $this, 'update_trip_post_data' ), 20 );
do_action( 'trip_saved_notification', 'pending', 'old_status', get_post( $post_id ) );
And then add it to the correct trigger:
add_action( 'notification/trigger/registered', function( $trigger ) {
// Check if registered Trigger is the one we need.
// Adjust the "trip" if this is not your CPT slug.
if ( 'wordpress/trip/pending' !== $trigger->get_slug() ) {
return;
}
// Add your action.
$trigger->add_action( 'trip_saved_notification', 10, 3 );
} );
This should do the job!