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



rest_preprocess_comment ›

Seit4.7.0
Veraltetn/v
apply_filters( 'rest_preprocess_comment', $prepared_comment, $request )
Parameter: (2)
  • (array) $prepared_comment The prepared comment data for `wp_insert_comment`.
    Erforderlich: Ja
  • (WP_REST_Request) $request The current request.
    Erforderlich: Ja
Definiert in:
Codex:

Filters a comment added via the REST API after it is prepared for insertion into the database.

Allows modification of the comment right after it is prepared for the database.





Quellcode

return apply_filters( 'rest_preprocess_comment', $prepared_comment, $request );