Make WordPress Core


Ignore:
Timestamp:
11/19/2020 06:22:02 PM (5 years ago)
Author:
johnbillion
Message:

Docs: Document parameters that accept an array of integers using typed array notation.

While many of these parameters also technically accept an array of numerical strings, they are all ultimately cast to an array of integers. Documenting them as such assists developers in understanding the expected types.

See #51800, #41756

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-site-query.php

    r49538 r49672  
    115115     *     Optional. Array or query string of site query parameters. Default empty.
    116116     *
    117      *     @type array        $site__in               Array of site IDs to include. Default empty.
    118      *     @type array        $site__not_in           Array of site IDs to exclude. Default empty.
     117     *     @type int[]        $site__in               Array of site IDs to include. Default empty.
     118     *     @type int[]        $site__not_in           Array of site IDs to exclude. Default empty.
    119119     *     @type bool         $count                  Whether to return a site count (true) or array of site objects.
    120120     *                                                Default false.
     
    136136     *     @type int          $network_id             Limit results to those affiliated with a given network ID. If 0,
    137137     *                                                include all networks. Default 0.
    138      *     @type array        $network__in            Array of network IDs to include affiliated sites for. Default empty.
    139      *     @type array        $network__not_in        Array of network IDs to exclude affiliated sites for. Default empty.
     138     *     @type int[]        $network__in            Array of network IDs to include affiliated sites for. Default empty.
     139     *     @type int[]        $network__not_in        Array of network IDs to exclude affiliated sites for. Default empty.
    140140     *     @type string       $domain                 Limit results to those affiliated with a given domain. Default empty.
    141141     *     @type array        $domain__in             Array of domains to include affiliated sites for. Default empty.
Note: See TracChangeset for help on using the changeset viewer.