Zapier_Provider::add_updated_to_queue( int $post_id, WP_Post $post_after, WP_Post $post_before )

Add a custom post id of an event that has been updated to a trigger queue.


Parameters

$post_id

(int) (Required) A WordPress custom post id.

$post_after

(WP_Post) (Required) Post object following the update.

$post_before

(WP_Post) (Required) Post object before the update.


Top ↑

Source

File: src/Common/Event_Automator/Zapier/Zapier_Provider.php

	public function add_updated_to_queue( $post_id, $post_after, $post_before ) {
		// TEC is not available return to prevent errors.
		if ( ! class_exists('Tribe__Events__Main' ) ) {
			return;
		}

		$data = [
			'post'        => $post_after,
			'post_before' => $post_before,
		];

		$this->container->make( Updated_Events::class )->add_to_queue( $post_id, $data );
	}

Top ↑

Changelog

Changelog
Version Description
6.0.0 Introduced.