WC_Comments::exclude_webhook_comments
Exclude webhook comments from queries and RSS.
Method of the class: WC_Comments{}
No Hooks.
Returns
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() WC Comments::exclude webhook comments code WC 10.4.3
public static function exclude_webhook_comments( $clauses ) {
$clauses['where'] .= ( trim( $clauses['where'] ) ? ' AND ' : '' ) . " comment_type != 'webhook_delivery' ";
return $clauses;
}