WC_Comments::is_comment_excluded_from_wp_comment_countsprivate staticWC 1.0

Determines whether the given comment should be included in the core WP comment counts that are displayed in the WordPress admin.

Method of the class: WC_Comments{}

No Hooks.

Returns

true|false.

Usage

$result = WC_Comments::is_comment_excluded_from_wp_comment_counts( $comment );
$comment(WP_Comment) (required)
Comment object.

WC_Comments::is_comment_excluded_from_wp_comment_counts() code WC 10.8.1

private static function is_comment_excluded_from_wp_comment_counts( $comment ) {
	return in_array( $comment->comment_type, array( 'action_log', 'order_note', 'webhook_delivery' ), true )
		|| get_post_type( $comment->comment_post_ID ) === 'product';
}