Activity_Helper::action_exists( string $action )

Description #

Check if activity action exists.

Parameters #

  • $action
    string (Required) Action key, must be below 20 characters.

Changelog #

VersionDescription
4.1.2Introduced.

Source #

File: includes/class/class-activity-helper.php

	public function action_exists( $action ) {
		// Get only actions key.
		$action_keys = array_keys( $this->actions );
		return in_array( $action, $action_keys, true );
	}

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Add your comment