Make WordPress Core

Changeset 55732


Ignore:
Timestamp:
05/08/2023 10:35:38 PM (19 months ago)
Author:
johnbillion
Message:

Docs: A host of corrections and improvements to inline documentation.

See #57840

Location:
trunk/src
Files:
25 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-application-passwords-list-table.php

    r55276 r55732  
    2222     * @since 5.6.0
    2323     *
    24      * @return array
     24     * @return string[] Array of column titles keyed by their column name.
    2525     */
    2626    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-comments-list-table.php

    r55513 r55732  
    459459     * @global int $post_id
    460460     *
    461      * @return array
     461     * @return string[] Array of column titles keyed by their column name.
    462462     */
    463463    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-links-list-table.php

    r55276 r55732  
    125125
    126126    /**
    127      * @return array
     127     * @return string[] Array of column titles keyed by their column name.
    128128     */
    129129    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-media-list-table.php

    r55703 r55732  
    321321
    322322    /**
    323      * @return array
     323     * @return string[] Array of column titles keyed by their column name.
    324324     */
    325325    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-ms-sites-list-table.php

    r55666 r55732  
    360360
    361361    /**
    362      * @return array
     362     * @return string[] Array of column titles keyed by their column name.
    363363     */
    364364    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-ms-themes-list-table.php

    r55276 r55732  
    323323
    324324    /**
    325      * @return array
     325     * @return string[] Array of column titles keyed by their column name.
    326326     */
    327327    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-ms-users-list-table.php

    r55276 r55732  
    186186
    187187    /**
    188      * @return array
     188     * @return string[] Array of column titles keyed by their column name.
    189189     */
    190190    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-plugin-install-list-table.php

    r55641 r55732  
    425425
    426426    /**
    427      * @return array
     427     * @return string[] Array of column titles keyed by their column name.
    428428     */
    429429    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-plugins-list-table.php

    r55571 r55732  
    452452    /**
    453453     * @global string $status
    454      * @return array
     454     *
     455     * @return string[] Array of column titles keyed by their column name.
    455456     */
    456457    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-posts-list-table.php

    r55703 r55732  
    652652
    653653    /**
    654      * @return array
     654     * @return string[] Array of column titles keyed by their column name.
    655655     */
    656656    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-terms-list-table.php

    r55276 r55732  
    186186
    187187    /**
    188      * @return array
     188     * @return string[] Array of column titles keyed by their column name.
    189189     */
    190190    public function get_columns() {
  • trunk/src/wp-admin/includes/class-wp-themes-list-table.php

    r54378 r55732  
    171171
    172172    /**
    173      * @return array
     173     * @return string[] Array of column titles keyed by their column name.
    174174     */
    175175    public function get_columns() {
  • trunk/src/wp-includes/block-template-utils.php

    r55694 r55732  
    13461346 * Gets the template hierarchy for the given template slug to be created.
    13471347 *
    1348  *
    13491348 * Note: Always add `index` as the last fallback template.
    13501349 *
  • trunk/src/wp-includes/class-wp-application-passwords.php

    r54133 r55732  
    6969     *     @type string $app_id A UUID provided by the application to uniquely identify it.
    7070     * }
    71      * @return array|WP_Error The first key in the array is the new password, the second is its detailed information.
    72      *                        A WP_Error instance is returned on error.
     71     * @return array|WP_Error {
     72     *     Application password details, or a WP_Error instance if an error occurs.
     73     *
     74     *     @type string $0 The unhashed generated application password.
     75     *     @type array  $1 {
     76     *         The details about the created password.
     77     *
     78     *         @type string $uuid      The unique identifier for the application password.
     79     *         @type string $app_id    A UUID provided by the application to uniquely identify it.
     80     *         @type string $name      The name of the application password.
     81     *         @type string $password  A one-way hash of the password.
     82     *         @type int    $created   Unix timestamp of when the password was created.
     83     *         @type null   $last_used Null.
     84     *         @type null   $last_ip   Null.
     85     *     }
     86     * }
    7387     */
    7488    public static function create_new_application_password( $user_id, $args = array() ) {
  • trunk/src/wp-includes/class-wp-block-supports.php

    r55230 r55732  
    9292     * @since 5.6.0
    9393     *
    94      * @return string[] Array of HTML attributes.
     94     * @return string[] Array of HTML attribute values keyed by their name.
    9595     */
    9696    public function apply_block_supports() {
  • trunk/src/wp-includes/class-wp-date-query.php

    r54765 r55732  
    686686     *
    687687     * @param array $query Date query arguments.
    688      * @return string[] {
     688     * @return array {
    689689     *     Array containing JOIN and WHERE SQL clauses to append to the main query.
    690690     *
    691      *     @type string $join  SQL fragment to append to the main JOIN clause.
    692      *     @type string $where SQL fragment to append to the main WHERE clause.
     691     *     @type string[] $join  Array of SQL fragments to append to the main JOIN clause.
     692     *     @type string[] $where Array of SQL fragments to append to the main WHERE clause.
    693693     * }
    694694     */
     
    706706     * @param array $query        Date query clause.
    707707     * @param array $parent_query Parent query of the current date query.
    708      * @return string[] {
     708     * @return array {
    709709     *     Array containing JOIN and WHERE SQL clauses to append to the main query.
    710710     *
    711      *     @type string $join  SQL fragment to append to the main JOIN clause.
    712      *     @type string $where SQL fragment to append to the main WHERE clause.
     711     *     @type string[] $join  Array of SQL fragments to append to the main JOIN clause.
     712     *     @type string[] $where Array of SQL fragments to append to the main WHERE clause.
    713713     * }
    714714     */
  • trunk/src/wp-includes/class-wp-meta-query.php

    r55398 r55732  
    524524     *                             parameters. If not provided, a key will be generated automatically.
    525525     *                             Default empty string.
    526      * @return string[] {
     526     * @return array {
    527527     *     Array containing JOIN and WHERE SQL clauses to append to a first-order query.
    528528     *
    529      *     @type string $join  SQL fragment to append to the main JOIN clause.
    530      *     @type string $where SQL fragment to append to the main WHERE clause.
     529     *     @type string[] $join  Array of SQL fragments to append to the main JOIN clause.
     530     *     @type string[] $where Array of SQL fragments to append to the main WHERE clause.
    531531     * }
    532532     */
  • trunk/src/wp-includes/class-wp-tax-query.php

    r54867 r55732  
    375375     * @param array $clause       Query clause (passed by reference).
    376376     * @param array $parent_query Parent query array.
    377      * @return string[] {
     377     * @return array {
    378378     *     Array containing JOIN and WHERE SQL clauses to append to a first-order query.
    379379     *
    380      *     @type string $join  SQL fragment to append to the main JOIN clause.
    381      *     @type string $where SQL fragment to append to the main WHERE clause.
     380     *     @type string[] $join  Array of SQL fragments to append to the main JOIN clause.
     381     *     @type string[] $where Array of SQL fragments to append to the main WHERE clause.
    382382     * }
    383383     */
  • trunk/src/wp-includes/class-wp-user-query.php

    r55680 r55732  
    6868
    6969    /**
    70      * PHP5 constructor.
     70     * Constructor.
    7171     *
    7272     * @since 3.1.0
    7373     *
    7474     * @param null|string|array $query Optional. The query variables.
     75     *                                 See WP_User_Query::prepare_query() for information on accepted arguments.
    7576     */
    7677    public function __construct( $query = null ) {
     
    8687     * @since 4.4.0
    8788     *
    88      * @param array $args Query vars, as passed to `WP_User_Query`.
     89     * @param string|array $args Query vars, as passed to `WP_User_Query`.
    8990     * @return array Complete query variables with undefined ones filled in with defaults.
    9091     */
     
    148149     *
    149150     * @param string|array $query {
    150      *     Optional. Array or string of Query parameters.
     151     *     Optional. Array or string of query parameters.
    151152     *
    152153     *     @type int             $blog_id             The site ID. Default is the current site.
  • trunk/src/wp-includes/class-wp-user.php

    r54891 r55732  
    895895     *
    896896     * @return bool[] List of capabilities keyed by the capability name,
    897      *                e.g. array( 'edit_posts' => true, 'delete_posts' => false ).
     897     *                e.g. `array( 'edit_posts' => true, 'delete_posts' => false )`.
    898898     */
    899899    private function get_caps_data() {
  • trunk/src/wp-includes/class-wpdb.php

    r55694 r55732  
    14381438     * Prepares a SQL query for safe execution.
    14391439     *
    1440      * Uses sprintf()-like syntax. The following placeholders can be used in the query string:
    1441      *
    1442      * - %d (integer)
    1443      * - %f (float)
    1444      * - %s (string)
    1445      * - %i (identifier, e.g. table/field names)
     1440     * Uses `sprintf()`-like syntax. The following placeholders can be used in the query string:
     1441     *
     1442     * - `%d` (integer)
     1443     * - `%f` (float)
     1444     * - `%s` (string)
     1445     * - `%i` (identifier, e.g. table/field names)
    14461446     *
    14471447     * All placeholders MUST be left unquoted in the query string. A corresponding argument
     
    14781478     * @since 6.2.0 Added `%i` for identifiers, e.g. table or field names.
    14791479     *              Check support via `wpdb::has_cap( 'identifier_placeholders' )`.
    1480      *              This preserves compatibility with sprintf(), as the C version uses
     1480     *              This preserves compatibility with `sprintf()`, as the C version uses
    14811481     *              `%d` and `$i` as a signed integer, whereas PHP only supports `%d`.
    14821482     *
    14831483     * @link https://www.php.net/sprintf Description of syntax.
    14841484     *
    1485      * @param string      $query   Query statement with sprintf()-like placeholders.
     1485     * @param string      $query   Query statement with `sprintf()`-like placeholders.
    14861486     * @param array|mixed $args    The array of variables to substitute into the query's placeholders
    14871487     *                             if being called with an array of arguments, or the first variable
     
    33203320     *     @type int    $length The column length.
    33213321     *     @type string $type   One of 'byte' or 'char'.
     3322     * }
    33223323     */
    33233324    public function get_col_length( $table, $column ) {
  • trunk/src/wp-includes/comment.php

    r55703 r55732  
    10601060 *                                 for the top-level parent `$comment_id`.
    10611061 *                                 Defaults to the value of the 'thread_comments_depth' option.
    1062  * } *
     1062 * }
    10631063 * @return int|null Comment page number or null on error.
    10641064 */
  • trunk/src/wp-includes/deprecated.php

    r55653 r55732  
    39363936
    39373937/**
    3938 * Ajax handler for saving a post from Press This.
    3939 *
    3940 * @since 4.2.0
    3941 * @deprecated 4.9.0
    3942 */
     3938 * Ajax handler for saving a post from Press This.
     3939 *
     3940 * @since 4.2.0
     3941 * @deprecated 4.9.0
     3942 */
    39433943function wp_ajax_press_this_save_post() {
    39443944    _deprecated_function( __FUNCTION__, '4.9.0' );
     
    39533953
    39543954/**
    3955 * Ajax handler for creating new category from Press This.
    3956 *
    3957 * @since 4.2.0
    3958 * @deprecated 4.9.0
    3959 */
     3955 * Ajax handler for creating new category from Press This.
     3956 *
     3957 * @since 4.2.0
     3958 * @deprecated 4.9.0
     3959 */
    39603960function wp_ajax_press_this_add_category() {
    39613961    _deprecated_function( __FUNCTION__, '4.9.0' );
     
    44474447
    44484448/**
    4449   * Allows multiple block styles.
    4450   *
    4451   * @since 5.9.0
    4452   * @deprecated 6.1.0
    4453   *
    4454   * @param array $metadata Metadata for registering a block type.
    4455   * @return array Metadata for registering a block type.
    4456   */
    4457   function _wp_multiple_block_styles( $metadata ) {
     4449 * Allows multiple block styles.
     4450 *
     4451 * @since 5.9.0
     4452 * @deprecated 6.1.0
     4453 *
     4454 * @param array $metadata Metadata for registering a block type.
     4455 * @return array Metadata for registering a block type.
     4456 */
     4457function _wp_multiple_block_styles( $metadata ) {
    44584458    _deprecated_function( __FUNCTION__, '6.1.0' );
    44594459    return $metadata;
     
    45994599 * @since 6.0.0
    46004600 * @deprecated 6.2.0 Site Editor's server-side redirect for missing postType and postId
    4601  *                   query args is removed. Thus, this function is no longer used.
     4601 *                   query args is removed. Thus, this function is no longer used.
    46024602 *
    46034603 * @return array|null A template object, or null if none could be found.
  • trunk/src/wp-includes/functions.wp-scripts.php

    r55072 r55732  
    8282 * @since 2.1.0
    8383 *
    84  * @param string|bool|array $handles Optional. Scripts to be printed. Default 'false'.
     84 * @param string|string[]|false $handles Optional. Scripts to be printed. Default 'false'.
    8585 * @return string[] On success, an array of handles of processed WP_Dependencies items; otherwise, an empty array.
    8686 */
  • trunk/src/wp-includes/post.php

    r55709 r55732  
    12261226 * @access private
    12271227 *
    1228  * @return array
     1228 * @return string[] Array of privacy request status labels keyed by their status.
    12291229 */
    12301230function _wp_privacy_statuses() {
Note: See TracChangeset for help on using the changeset viewer.