Make WordPress Core

Changeset 52110


Ignore:
Timestamp:
11/10/2021 02:16:03 PM (3 years ago)
Author:
desrosj
Message:

Docs: Avoid using “CPT” instead of “custom post type”.

Additionally, when referring to built in Core post types, “custom” is unnecessary.

This also adds a period to the end of the wp_global_styles post type description.

Follow up to [38829], [51003], [52041], [52049], [52062].

See #53399, #54335, #54336.

Location:
trunk/src/wp-includes
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/block-template-utils.php

    r52062 r52110  
    601601    }
    602602
    603     // This is only needed for the regular templates/template parts CPT listing and editor.
     603    // This is only needed for the regular templates/template parts post type listing and editor.
    604604    if ( isset( $query['wp_id'] ) ) {
    605605        $wp_query_args['p'] = $query['wp_id'];
  • trunk/src/wp-includes/class-wp-theme-json-resolver.php

    r52077 r52110  
    191191
    192192    /**
    193      * Returns the CPT that contains the user's origin config
    194      * for the current theme or a void array if none found.
    195      *
    196      * It can also create and return a new draft CPT.
     193     * Returns the custom post type that contains the user's origin config
     194     * for the current theme or a void array if none are found.
     195     *
     196     * This can also create and return a new draft custom post type.
    197197     *
    198198     * @since 5.9.0
    199199     *
    200      * @param bool  $should_create_cpt  Optional. Whether a new CPT should be created if no one was found.
     200     * @param bool  $should_create_cpt  Optional. Whether a new custom post type should be created if none are found.
    201201     *                                  False by default.
    202      * @param array $post_status_filter Filter Optional. CPT by post status.
     202     * @param array $post_status_filter Filter Optional. custom post type by post status.
    203203     *                                   ['publish'] by default, so it only fetches published posts.
    204204     *
  • trunk/src/wp-includes/default-filters.php

    r52069 r52110  
    663663add_filter( 'user_has_cap', 'wp_maybe_grant_site_health_caps', 1, 4 );
    664664
    665 // Block Templates CPT and Rendering
     665// Block Templates post type and Rendering
    666666add_filter( 'render_block_context', '_block_template_render_without_post_block_context' );
    667667add_filter( 'pre_wp_unique_post_slug', 'wp_filter_wp_template_unique_post_slug', 10, 5 );
  • trunk/src/wp-includes/post.php

    r52109 r52110  
    451451        array(
    452452            'label'        => __( 'Global Styles' ),
    453             'description'  => __( 'CPT to store user design tokens' ),
     453            'description'  => __( 'Post type for storing user design tokens.' ),
    454454            'public'       => false,
    455455            '_builtin'     => true, /* internal use only. don't use this when registering your own post type. */
  • trunk/src/wp-includes/theme.php

    r52069 r52110  
    19141914     * @since 4.7.0
    19151915     *
    1916      * @param string $css        CSS pulled in from the Custom CSS CPT.
     1916     * @param string $css        CSS pulled in from the Custom CSS post type.
    19171917     * @param string $stylesheet The theme stylesheet name.
    19181918     */
Note: See TracChangeset for help on using the changeset viewer.