Make WordPress Core


Ignore:
Timestamp:
01/10/2021 10:21:39 PM (4 years ago)
Author:
johnbillion
Message:

REST API: Corrections and improvements to docblocks for REST API filters.

See #51800

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-comments-controller.php

    r49610 r49955  
    450450
    451451            /**
    452              * Filters whether comments can be created without authentication.
     452             * Filters whether comments can be created via the REST API without authentication.
    453453             *
    454454             * Enables creating comments for anonymous users.
     
    956956
    957957        /**
    958          * Filters whether a comment can be trashed.
    959          *
    960          * Return false to disable Trash support for the post.
     958         * Filters whether a comment can be trashed via the REST API.
     959         *
     960         * Return false to disable trash support for the comment.
    961961         *
    962962         * @since 4.7.0
    963963         *
    964          * @param bool    $supports_trash Whether the post type support trashing.
    965          * @param WP_Post $comment        The comment object being considered for trashing support.
     964         * @param bool       $supports_trash Whether the comment supports trashing.
     965         * @param WP_Comment $comment        The comment object being considered for trashing support.
    966966         */
    967967        $supports_trash = apply_filters( 'rest_comment_trashable', ( EMPTY_TRASH_DAYS > 0 ), $comment );
     
    13521352
    13531353        /**
    1354          * Filters a comment after it is prepared for the database.
     1354         * Filters a comment added via the REST API after it is prepared for insertion into the database.
    13551355         *
    13561356         * Allows modification of the comment right after it is prepared for the database.
     
    16751675
    16761676        /**
    1677          * Filters collection parameters for the comments controller.
     1677         * Filters REST API collection parameters for the comments controller.
    16781678         *
    16791679         * This filter registers the collection parameter, but does not map the
Note: See TracChangeset for help on using the changeset viewer.