wpseek.com
Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren



rest_comment_trashable › WordPress Filter Hooks

Seit4.7.0
Veraltetn/v
apply_filters( 'rest_comment_trashable', ( EMPTY_TRASH_DAYS > 0 )
Parameter: (2)
  • (bool) $supports_trash Whether the comment supports trashing.
    Erforderlich: Ja
  • (WP_Comment) $comment The comment object being considered for trashing support.
    Erforderlich: Ja
Definiert in:
Codex:

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

Return false to disable trash support for the comment.





Quellcode

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