UT_USER_IMPORTED::define_trigger()

Define and register the trigger by pushing it into the Automator object


Source Source

File: src/integrations/uncanny-toolkit/triggers/ut-user-imported.php

	public function define_trigger() {

		$trigger = array(
			'author'              => Automator()->get_author_name( $this->trigger_code ),
			'support_link'        => Automator()->get_author_support_link( $this->trigger_code, 'integration/uncanny-toolkit/' ),
			'integration'         => self::$integration,
			'code'                => $this->trigger_code,
			'meta'                => $this->trigger_meta,
			/* translators: Logged-in trigger - Uncanny Toolkit */
			'sentence'            => esc_attr__( 'A user is imported by the Import Users module', 'uncanny-automator' ),
			/* translators: Logged-in trigger - Uncanny Toolkit */
			'select_option_name'  => esc_attr__( 'A user is imported by the Import Users module', 'uncanny-automator' ),
			'action'              => 'uo_after_user_row_imported',
			'priority'            => 20,
			'accepted_args'       => 4,
			'validation_function' => array( $this, 'a_user_is_imported' ),
			'options'             => array(),
		);

		Automator()->register->trigger( $trigger );
	}