Make WordPress Core

Changeset 57150


Ignore:
Timestamp:
12/03/2023 07:59:10 PM (12 months ago)
Author:
SergeyBiryukov
Message:

Docs: Add missing argument type for supports in register_post_type().

If set to false, no feature support is registered for the post type.

Follow-up to [12751], [20734], [29091], [37883].

Props jeremyfelt, swissspidy.
Fixes #59690.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/post.php

    r56925 r57150  
    16241624 *     @type string|bool  $autosave_rest_controller_class  REST API controller class name. Default is 'WP_REST_Autosaves_Controller'.
    16251625 *     @type string|bool  $revisions_rest_controller_class REST API controller class name. Default is 'WP_REST_Revisions_Controller'.
    1626  *     @type bool         $late_route_registration         A flag to direct the REST API controllers for autosave / revisions should be registered before/after the post type controller.
     1626 *     @type bool         $late_route_registration         A flag to direct the REST API controllers for autosave / revisions
     1627 *                                                         should be registered before/after the post type controller.
    16271628 *     @type int          $menu_position                   The position in the menu order the post type should appear. To work,
    16281629 *                                                         $show_in_menu must be true. Default null (at the bottom).
     
    16421643 *     @type bool         $map_meta_cap                    Whether to use the internal default meta capability handling.
    16431644 *                                                         Default false.
    1644  *     @type array        $supports                        Core feature(s) the post type supports. Serves as an alias for calling
     1645 *     @type array|false  $supports                        Core feature(s) the post type supports. Serves as an alias for calling
    16451646 *                                                         add_post_type_support() directly. Core features include 'title',
    16461647 *                                                         'editor', 'comments', 'revisions', 'trackbacks', 'author', 'excerpt',
     
    16521653 *                                                         about supporting that feature.
    16531654 *                                                         Example: `array( 'my_feature', array( 'field' => 'value' ) )`.
     1655 *                                                         If false, no features will be added.
    16541656 *                                                         Default is an array containing 'title' and 'editor'.
    16551657 *     @type callable     $register_meta_box_cb            Provide a callback function that sets up the meta boxes for the
Note: See TracChangeset for help on using the changeset viewer.