WP_CLI

Runner::is_command_disabled()publicWP-CLI 1.0

Check whether a given command is disabled by the config.

Method of the class: Runner{}

No Hooks.

Return

true|false.

Usage

$Runner = new Runner();
$Runner->is_command_disabled( $command );
$command (required)
-

Runner::is_command_disabled() code WP-CLI 2.8.0-alpha

public function is_command_disabled( $command ) {
	$path = implode( ' ', array_slice( Dispatcher\get_path( $command ), 1 ) );
	return in_array( $path, $this->config['disabled_commands'], true );
}