Tribe__Events__Aggregator__Settings::is_ea_authorized_for_meetup()

Check if the Meetup API credentials are connected in EA and correctly set.


Return

(bool) Whether the Meetup credentials are valid or not.


Top ↑

Source

File: src/Tribe/Aggregator/Settings.php

	public function is_ea_authorized_for_meetup() {
		// If the service hasn't enabled oauth for Meetup, always assume it is valid.
		if ( ! tribe( 'events-aggregator.main' )->api( 'origins' )->is_oauth_enabled( 'meetup' ) ) {
			return true;
		}

		$request_secret_key = ! $this->has_meetup_security_key();
		$meetup_authorized  = tribe( 'events-aggregator.service' )->has_meetup_authorized( $request_secret_key );

		if ( empty( $meetup_authorized->status ) || 'success' !== $meetup_authorized->status ) {
			return false;
		}

		if ( ! $this->handle_meetup_security_key( $meetup_authorized ) ) {
			return false;
		}

		return true;
	}

Top ↑

Changelog

Changelog
Version Description
4.9.6 Introduced.