wpseek.com
Uma área de pesquisa sobre o WordPress para devs e autores do tema



rest_comment_trashable › Hooks de Filtros WordPress

Desde4.7.0
Obsoleton/a
apply_filters( 'rest_comment_trashable', ( EMPTY_TRASH_DAYS > 0 )
Parâmetros: (2)
  • (bool) $supports_trash Whether the comment supports trashing.
    Required: Yes
  • (WP_Comment) $comment The comment object being considered for trashing support.
    Required: Yes
Definido em:
Codex:

Filters whether a comment can be trashed via the REST API.

Return false to disable trash support for the comment.





Fonte

$supports_trash = apply_filters( 'rest_comment_trashable', ( EMPTY_TRASH_DAYS > 0 ), $comment );