FACEBOOK_PAGE_PUBLISH_POST::__construct()


Source Source

File: src/integrations/facebook/actions/facebook-page-publish-post.php

	public function __construct() {

		$this->fb_pages_wp_ajax_endpoint = 'fb_pages_wp_ajax_endpoint_post_page';

		$this->fb_endpoint_uri = AUTOMATOR_API_URL . 'v2/facebook';

		// Allow overwrite in wp-config.php.
		if ( DEFINED( 'UO_AUTOMATOR_DEV_FB_ENDPOINT_URL' ) ) {
			$this->fb_endpoint_uri = UO_AUTOMATOR_DEV_FB_ENDPOINT_URL;
		}

		add_action( "wp_ajax_{$this->fb_pages_wp_ajax_endpoint}", array( $this, $this->fb_pages_wp_ajax_endpoint ) );

		$this->setup_action();

	}