Add_Facebook_Integration::add_integration_func()

Registers Integration.


Source Source

File: src/integrations/facebook/add-facebook-integration.php

	public function add_integration_func() {

		$facebook_options_user = get_option( '_uncannyowl_facebook_settings', array() );
		$facebook_options_pages = get_option( '_uncannyowl_facebook_pages_settings', array() );

		if ( ! empty( $facebook_options_user ) && ! empty( $facebook_options_pages ) ) {
			$this->connected = true;
		}

		// set up configuration.
		$integration_config = array(
			'name'     => 'Facebook',
			'icon_svg' => Utilities::automator_get_integration_icon( __DIR__ . '/img/facebook-icon.svg' ),
			'connected' => $this->connected, // 
			'settings_url' => admin_url( 'edit.php' ) . '?post_type=uo-recipe&page=uncanny-automator-settings&tab=facebook_api',
		);

		// register integration into automator.
		Automator()->register->integration( self::$integration, $integration_config );

	}


Top ↑

Changelog Changelog

Changelog
Version Description
2.4.0 Introduced.