WC_Comments::exclude_webhook_comments()public staticWC 2.2

Exclude webhook comments from queries and RSS.

Method of the class: WC_Comments{}

No Hooks.

Return

Array.

Usage

$result = WC_Comments::exclude_webhook_comments( $clauses );
$clauses(array) (required)
A compacted array of comment query clauses.

Changelog

Since 2.2 Introduced.

WC_Comments::exclude_webhook_comments() code WC 9.4.2

public static function exclude_webhook_comments( $clauses ) {
	$clauses['where'] .= ( $clauses['where'] ? ' AND ' : '' ) . " comment_type != 'webhook_delivery' ";
	return $clauses;
}