Filters whether a comment can be trashed via the REST API. Return false to disable trash support for the comment.
( EMPTY_TRASH_DAYS > 0
Sortie :
@param bool $supports_trash Whether the comment supports trashing. @param WP_Comment $comment The comment object being considered for trashing support.
// Modifier la valeur avec le filtre 'rest_comment_trashable'
add_filter('rest_comment_trashable', 'ma_fonction_filtre', 10, 1);
function ma_fonction_filtre(( EMPTY_TRASH_DAYS > 0) {
// Modifier la valeur
return ( EMPTY_TRASH_DAYS > 0;
}
Chargement des actualités...