WC_Comments::exclude_webhook_comments()public staticWC 2.2

Exclude webhook comments from queries and RSS.

Метод класса: WC_Comments{}

Хуков нет.

Возвращает

Массив.

Использование

$result = WC_Comments::exclude_webhook_comments( $clauses );
$clauses(массив) (обязательный)
A compacted array of comment query clauses.

Список изменений

С версии 2.2 Введена.

Код WC_Comments::exclude_webhook_comments() WC 8.7.0

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