Browse: Home / Functions /

learndash_remove_comments

learndash_remove_comments( array $comments = array(),  int $post_id )

Removes all comments for learndash post types.


Description #

Fires on ‘comments_array’ hook.


Parameters #

$comments

(array) (Optional) An array of comments for a post ID.

Default value: array()

$post_id

(int) (Optional) Post ID.


Return #

(array) An empty array.


Source #

File: includes/ld-misc-functions.php


Changelog #

Changelog
Version Description
2.1.0 Introduced.