This hook can be used to filter the comments appearing in the live update.
Changelog
Since 7.0.0 version
Parameters
1. $newCommentIds (type: array) – the array of the new comments’ IDs
2. $postId (type: int) – the parent post ID of the comments
3. $currentUser (type: WP_User object)- the object of the current user
Usage
add_filter("wpdiscuz_live_update_new_comment_ids", function ($newCommentIds, $postId, $currentUser) { if ($postId == 57) { $newCommentIds = array_slice($newCommentIds, 0, 5); } return $newCommentIds; }, 10, 3);