Make WordPress Core


Ignore:
Timestamp:
03/25/2018 07:32:24 PM (8 years ago)
Author:
johnbillion
Message:

Docs: Document more parameters and properties using typed array notation.

See #41756

File:
1 edited

Legend:

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

    r42875 r42876  
    11921192                 * @since 4.7.0 Added the `$post_type` parameter.
    11931193                 *
    1194                  * @param array        $post_templates Array of page templates. Keys are filenames,
     1194                 * @param string[]     $post_templates Array of page templates. Keys are filenames,
    11951195                 *                                     values are translated names.
    11961196                 * @param WP_Theme     $this           The theme object.
     
    12401240                 * @since 4.7.4
    12411241                 *
    1242                  * @param array $exclusions Array of excluded directories and files.
     1242                 * @param string[] $exclusions Array of excluded directories and files.
    12431243                 */
    12441244                $exclusions = (array) apply_filters( 'theme_scandir_exclusions', array( 'CVS', 'node_modules', 'vendor', 'bower_components' ) );
     
    13571357         *
    13581358         * @param int $blog_id Optional. ID of the site. Defaults to the current site.
    1359          * @return array Array of stylesheet names.
     1359         * @return string[] Array of stylesheet names.
    13601360         */
    13611361        public static function get_allowed( $blog_id = null ) {
     
    13681368                 * @since 4.5.0
    13691369                 *
    1370                  * @param array $allowed_themes An array of theme stylesheet names.
    1371                  * @param int   $blog_id        ID of the site.
     1370                 * @param string[] $allowed_themes An array of theme stylesheet names.
     1371                 * @param int      $blog_id        ID of the site.
    13721372                 */
    13731373                $network = (array) apply_filters( 'network_allowed_themes', self::get_allowed_on_network(), $blog_id );
     
    13821382         * @staticvar array $allowed_themes
    13831383         *
    1384          * @return array Array of stylesheet names.
     1384         * @return string[] Array of stylesheet names.
    13851385         */
    13861386        public static function get_allowed_on_network() {
     
    13951395                 * @since MU (3.0.0)
    13961396                 *
    1397                  * @param array $allowed_themes An array of theme stylesheet names.
     1397                 * @param string[] $allowed_themes An array of theme stylesheet names.
    13981398                 */
    13991399                $allowed_themes = apply_filters( 'allowed_themes', $allowed_themes );
     
    14101410         *
    14111411         * @param int $blog_id Optional. ID of the site. Defaults to the current site.
    1412          * @return array Array of stylesheet names.
     1412         * @return string[] Array of stylesheet names.
    14131413         */
    14141414        public static function get_allowed_on_site( $blog_id = null ) {
     
    14251425                         * @since 4.5.0
    14261426                         *
    1427                          * @param array $allowed_themes An array of theme stylesheet names.
    1428                          * @param int   $blog_id        ID of the site. Defaults to current site.
     1427                         * @param string[] $allowed_themes An array of theme stylesheet names.
     1428                         * @param int      $blog_id        ID of the site. Defaults to current site.
    14291429                         */
    14301430                        return (array) apply_filters( 'site_allowed_themes', $allowed_themes[ $blog_id ], $blog_id );
     
    14871487         * @since 4.6.0
    14881488         *
    1489          * @param string|array $stylesheets Stylesheet name or array of stylesheet names.
     1489         * @param string|string[] $stylesheets Stylesheet name or array of stylesheet names.
    14901490         */
    14911491        public static function network_enable_theme( $stylesheets ) {
     
    15111511         * @since 4.6.0
    15121512         *
    1513          * @param string|array $stylesheets Stylesheet name or array of stylesheet names.
     1513         * @param string|string[] $stylesheets Stylesheet name or array of stylesheet names.
    15141514         */
    15151515        public static function network_disable_theme( $stylesheets ) {
Note: See TracChangeset for help on using the changeset viewer.