WP_CLI

ComposerIO::output_clean_message()private staticWP-CLI 1.0

Method of the class: ComposerIO{}

No Hooks.

Return

null. Nothing.

Usage

$result = ComposerIO::output_clean_message( $messages );
$messages (required)
-

ComposerIO::output_clean_message() code WP-CLI 2.8.0-alpha

private static function output_clean_message( $messages ) {
	$messages = (array) preg_replace( '#<(https?)([^>]+)>#', '$1$2', $messages );
	foreach ( $messages as $message ) {
		// phpcs:ignore WordPress.WP.AlternativeFunctions.strip_tags_strip_tags
		WP_CLI::log( strip_tags( trim( $message ) ) );
	}
}