diff --git a/src/wp-admin/edit-form-advanced.php b/src/wp-admin/edit-form-advanced.php index 9e1a33c09b..677e3dfbb0 100644 --- a/src/wp-admin/edit-form-advanced.php +++ b/src/wp-admin/edit-form-advanced.php @@ -193,7 +193,7 @@ $messages['attachment'] = array_fill( 1, 10, __( 'Media file updated.' ) ); // H * * @since 3.0.0 * - * @param array $messages Post updated messages. For defaults @see $messages declarations above. + * @param array[] $messages Post updated messages. For defaults see `$messages` declarations above. */ $messages = apply_filters( 'post_updated_messages', $messages ); diff --git a/src/wp-admin/edit.php b/src/wp-admin/edit.php index 1e8bef5a07..b1ad058912 100644 --- a/src/wp-admin/edit.php +++ b/src/wp-admin/edit.php @@ -329,9 +329,9 @@ $bulk_messages['page'] = array( * * @since 3.7.0 * - * @param array $bulk_messages Arrays of messages, each keyed by the corresponding post type. Messages are - * keyed with 'updated', 'locked', 'deleted', 'trashed', and 'untrashed'. - * @param array $bulk_counts Array of item counts for each message, used to build internationalized strings. + * @param array[] $bulk_messages Arrays of messages, each keyed by the corresponding post type. Messages are + * keyed with 'updated', 'locked', 'deleted', 'trashed', and 'untrashed'. + * @param int[] $bulk_counts Array of item counts for each message, used to build internationalized strings. */ $bulk_messages = apply_filters( 'bulk_post_updated_messages', $bulk_messages, $bulk_counts ); $bulk_counts = array_filter( $bulk_counts ); diff --git a/src/wp-admin/includes/bookmark.php b/src/wp-admin/includes/bookmark.php index 0572b73dec..5475d3d67f 100644 --- a/src/wp-admin/includes/bookmark.php +++ b/src/wp-admin/includes/bookmark.php @@ -253,7 +253,7 @@ function wp_insert_link( $linkdata, $wp_error = false ) { * @since 2.1.0 * * @param int $link_id ID of the link to update. - * @param array $link_categories Array of link categories to add the link to. + * @param int[] $link_categories Array of link category IDs to add the link to. */ function wp_set_link_cats( $link_id = 0, $link_categories = array() ) { // If $link_categories isn't already an array, make it one: diff --git a/src/wp-admin/includes/class-bulk-plugin-upgrader-skin.php b/src/wp-admin/includes/class-bulk-plugin-upgrader-skin.php index bb85e88be2..f2472f0db5 100644 --- a/src/wp-admin/includes/class-bulk-plugin-upgrader-skin.php +++ b/src/wp-admin/includes/class-bulk-plugin-upgrader-skin.php @@ -55,7 +55,7 @@ class Bulk_Plugin_Upgrader_Skin extends Bulk_Upgrader_Skin { * * @since 3.0.0 * - * @param array $update_actions Array of plugin action links. + * @param string[] $update_actions Array of plugin action links. * @param array $plugin_info Array of information for the last-updated plugin. */ $update_actions = apply_filters( 'update_bulk_plugins_complete_actions', $update_actions, $this->plugin_info ); diff --git a/src/wp-admin/includes/class-bulk-theme-upgrader-skin.php b/src/wp-admin/includes/class-bulk-theme-upgrader-skin.php index 09d42a1852..1ac8d3c6c5 100644 --- a/src/wp-admin/includes/class-bulk-theme-upgrader-skin.php +++ b/src/wp-admin/includes/class-bulk-theme-upgrader-skin.php @@ -55,7 +55,7 @@ class Bulk_Theme_Upgrader_Skin extends Bulk_Upgrader_Skin { * * @since 3.0.0 * - * @param array $update_actions Array of theme action links. + * @param string[] $update_actions Array of theme action links. * @param WP_Theme $theme_info Theme object for the last-updated theme. */ $update_actions = apply_filters( 'update_bulk_theme_complete_actions', $update_actions, $this->theme_info ); diff --git a/src/wp-admin/includes/class-language-pack-upgrader-skin.php b/src/wp-admin/includes/class-language-pack-upgrader-skin.php index 4fa1f29d38..3eb46cfd87 100644 --- a/src/wp-admin/includes/class-language-pack-upgrader-skin.php +++ b/src/wp-admin/includes/class-language-pack-upgrader-skin.php @@ -77,7 +77,7 @@ class Language_Pack_Upgrader_Skin extends WP_Upgrader_Skin { * * @since 3.7.0 * - * @param array $update_actions Array of translations update links. + * @param string[] $update_actions Array of translations update links. */ $update_actions = apply_filters( 'update_translations_complete_actions', $update_actions ); diff --git a/src/wp-admin/includes/class-language-pack-upgrader.php b/src/wp-admin/includes/class-language-pack-upgrader.php index 118d339d02..8e808608fa 100644 --- a/src/wp-admin/includes/class-language-pack-upgrader.php +++ b/src/wp-admin/includes/class-language-pack-upgrader.php @@ -151,15 +151,16 @@ class Language_Pack_Upgrader extends WP_Upgrader { * * @global WP_Filesystem_Base $wp_filesystem WordPress filesystem subclass. * - * @param array $language_updates Optional. Language pack updates. Default empty array. - * @param array $args { - * Optional. Other arguments for upgrading multiple language packs. Default empty array + * @param object[] $language_updates Optional. Array of language packs to update. @see wp_get_translation_updates(). + * Default empty array. + * @param array $args { + * Other arguments for upgrading multiple language packs. Default empty array. * * @type bool $clear_update_cache Whether to clear the update cache when done. * Default true. * } * @return array|bool|WP_Error Will return an array of results, or true if there are no updates, - * false or WP_Error for initial errors. + * false or WP_Error for initial errors. */ public function bulk_upgrade( $language_updates = array(), $args = array() ) { global $wp_filesystem; diff --git a/src/wp-admin/includes/class-plugin-installer-skin.php b/src/wp-admin/includes/class-plugin-installer-skin.php index 737837f2b5..b4d2574451 100644 --- a/src/wp-admin/includes/class-plugin-installer-skin.php +++ b/src/wp-admin/includes/class-plugin-installer-skin.php @@ -89,11 +89,11 @@ class Plugin_Installer_Skin extends WP_Upgrader_Skin { * * @since 2.7.0 * - * @param array $install_actions Array of plugin action links. - * @param object $api Object containing WordPress.org API plugin data. Empty - * for non-API installs, such as when a plugin is installed - * via upload. - * @param string $plugin_file Path to the plugin file relative to the plugins directory. + * @param string[] $install_actions Array of plugin action links. + * @param object $api Object containing WordPress.org API plugin data. Empty + * for non-API installs, such as when a plugin is installed + * via upload. + * @param string $plugin_file Path to the plugin file relative to the plugins directory. */ $install_actions = apply_filters( 'install_plugin_complete_actions', $install_actions, $this->api, $plugin_file ); diff --git a/src/wp-admin/includes/class-plugin-upgrader-skin.php b/src/wp-admin/includes/class-plugin-upgrader-skin.php index 0e24da4a1d..87cbefbc7d 100644 --- a/src/wp-admin/includes/class-plugin-upgrader-skin.php +++ b/src/wp-admin/includes/class-plugin-upgrader-skin.php @@ -64,8 +64,8 @@ class Plugin_Upgrader_Skin extends WP_Upgrader_Skin { * * @since 2.7.0 * - * @param array $update_actions Array of plugin action links. - * @param string $plugin Path to the plugin file relative to the plugins directory. + * @param string[] $update_actions Array of plugin action links. + * @param string $plugin Path to the plugin file relative to the plugins directory. */ $update_actions = apply_filters( 'update_plugin_complete_actions', $update_actions, $this->plugin ); diff --git a/src/wp-admin/includes/class-theme-installer-skin.php b/src/wp-admin/includes/class-theme-installer-skin.php index 32302fea5d..9d1a7993f8 100644 --- a/src/wp-admin/includes/class-theme-installer-skin.php +++ b/src/wp-admin/includes/class-theme-installer-skin.php @@ -104,7 +104,7 @@ class Theme_Installer_Skin extends WP_Upgrader_Skin { * * @since 2.8.0 * - * @param array $install_actions Array of theme action links. + * @param string[] $install_actions Array of theme action links. * @param object $api Object containing WordPress.org API theme data. * @param string $stylesheet Theme directory name. * @param WP_Theme $theme_info Theme object. diff --git a/src/wp-admin/includes/class-theme-upgrader-skin.php b/src/wp-admin/includes/class-theme-upgrader-skin.php index b5f03017ca..68569321b6 100644 --- a/src/wp-admin/includes/class-theme-upgrader-skin.php +++ b/src/wp-admin/includes/class-theme-upgrader-skin.php @@ -85,8 +85,8 @@ class Theme_Upgrader_Skin extends WP_Upgrader_Skin { * * @since 2.8.0 * - * @param array $update_actions Array of theme action links. - * @param string $theme Theme directory name. + * @param string[] $update_actions Array of theme action links. + * @param string $theme Theme directory name. */ $update_actions = apply_filters( 'update_theme_complete_actions', $update_actions, $this->theme ); diff --git a/src/wp-admin/includes/class-theme-upgrader.php b/src/wp-admin/includes/class-theme-upgrader.php index 8f125786e8..1a561ab69c 100644 --- a/src/wp-admin/includes/class-theme-upgrader.php +++ b/src/wp-admin/includes/class-theme-upgrader.php @@ -320,8 +320,8 @@ class Theme_Upgrader extends WP_Upgrader { * @since 3.0.0 * @since 3.7.0 The `$args` parameter was added, making clearing the update cache optional. * - * @param array $themes The theme slugs. - * @param array $args { + * @param string[] $themes Array of the theme slugs. + * @param array $args { * Optional. Other arguments for upgrading several themes at once. Default empty array. * * @type bool $clear_update_cache Whether to clear the update cache if successful. diff --git a/src/wp-admin/includes/class-wp-comments-list-table.php b/src/wp-admin/includes/class-wp-comments-list-table.php index 14e743ccb3..7ab35735a7 100644 --- a/src/wp-admin/includes/class-wp-comments-list-table.php +++ b/src/wp-admin/includes/class-wp-comments-list-table.php @@ -381,7 +381,7 @@ if ( 'top' === $which ) { * * @since 2.7.0 * - * @param array $comment_types An array of comment types. Accepts 'Comments', 'Pings'. + * @param string[] $comment_types An array of comment types. Accepts 'Comments', 'Pings'. */ $comment_types = apply_filters( 'admin_comment_types_dropdown', array( diff --git a/src/wp-admin/includes/class-wp-list-table.php b/src/wp-admin/includes/class-wp-list-table.php index ef6b633a3a..f31f4eaed6 100644 --- a/src/wp-admin/includes/class-wp-list-table.php +++ b/src/wp-admin/includes/class-wp-list-table.php @@ -396,7 +396,7 @@ class WP_List_Table { * * @since 3.5.0 * - * @param array $views An array of available list table views. + * @param string[] $views An array of available list table views. */ $views = apply_filters( "views_{$this->screen->id}", $views ); @@ -447,7 +447,7 @@ class WP_List_Table { * * @since 3.5.0 * - * @param array $actions An array of the available bulk actions. + * @param string[] $actions An array of the available bulk actions. */ $this->_actions = apply_filters( "bulk_actions-{$this->screen->id}", $this->_actions ); $two = ''; @@ -503,8 +503,8 @@ class WP_List_Table { * * @since 3.1.0 * - * @param array $actions The list of actions - * @param bool $always_visible Whether the actions should be always visible + * @param string[] $actions An array of action links. + * @param bool $always_visible Whether the actions should be always visible. * @return string */ protected function row_actions( $actions, $always_visible = false ) { diff --git a/src/wp-admin/includes/class-wp-media-list-table.php b/src/wp-admin/includes/class-wp-media-list-table.php index 70cb1a951f..4b29ba67b9 100644 --- a/src/wp-admin/includes/class-wp-media-list-table.php +++ b/src/wp-admin/includes/class-wp-media-list-table.php @@ -286,8 +286,8 @@ if ( ! empty( $views ) ) { * * @since 3.5.0 * - * @param array $taxonomies An array of registered taxonomies to show for attachments. - * @param string $post_type The post type. Default 'attachment'. + * @param string[] $taxonomies An array of registered taxonomy names to show for attachments. + * @param string $post_type The post type. Default 'attachment'. */ $taxonomies = apply_filters( 'manage_taxonomies_for_attachment_columns', $taxonomies, 'attachment' ); $taxonomies = array_filter( $taxonomies, 'taxonomy_exists' ); @@ -317,9 +317,9 @@ if ( ! empty( $views ) ) { * * @since 2.5.0 * - * @param array $posts_columns An array of columns displayed in the Media list table. - * @param bool $detached Whether the list table contains media not attached - * to any posts. Default true. + * @param string[] $posts_columns An array of columns displayed in the Media list table. + * @param bool $detached Whether the list table contains media not attached + * to any posts. Default true. */ return apply_filters( 'manage_media_columns', $posts_columns, $this->detached ); } @@ -755,11 +755,11 @@ if ( ! empty( $views ) ) { * * @since 2.8.0 * - * @param array $actions An array of action links for each attachment. - * Default 'Edit', 'Delete Permanently', 'View'. - * @param WP_Post $post WP_Post object for the current attachment. - * @param bool $detached Whether the list table contains media not attached - * to any posts. Default true. + * @param string[] $actions An array of action links for each attachment. + * Default 'Edit', 'Delete Permanently', 'View'. + * @param WP_Post $post WP_Post object for the current attachment. + * @param bool $detached Whether the list table contains media not attached + * to any posts. Default true. */ return apply_filters( 'media_row_actions', $actions, $post, $this->detached ); } diff --git a/src/wp-admin/includes/class-wp-ms-sites-list-table.php b/src/wp-admin/includes/class-wp-ms-sites-list-table.php index 1741d515f8..a8bbf917b8 100644 --- a/src/wp-admin/includes/class-wp-ms-sites-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-sites-list-table.php @@ -248,8 +248,8 @@ class WP_MS_Sites_List_Table extends WP_List_Table { * * @since MU (3.0.0) * - * @param array $sites_columns An array of displayed site columns. Default 'cb', - * 'blogname', 'lastupdated', 'registered', 'users'. + * @param string[] $sites_columns An array of displayed site columns. Default 'cb', + * 'blogname', 'lastupdated', 'registered', 'users'. */ return apply_filters( 'wpmu_blogs_columns', $sites_columns ); } @@ -273,6 +273,8 @@ class WP_MS_Sites_List_Table extends WP_List_Table { * @param array $blog Current site. */ public function column_cb( $blog ) { + var_dump($blog); + exit; if ( ! is_main_site( $blog['blog_id'] ) ) : $blogname = untrailingslashit( $blog['domain'] . $blog['path'] ); ?> @@ -569,10 +571,10 @@ class WP_MS_Sites_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $actions An array of action links to be displayed. - * @param int $blog_id The site ID. - * @param string $blogname Site path, formatted depending on whether it is a sub-domain - * or subdirectory multisite installation. + * @param string[] $actions An array of action links to be displayed. + * @param int $blog_id The site ID. + * @param string $blogname Site path, formatted depending on whether it is a sub-domain + * or subdirectory multisite installation. */ $actions = apply_filters( 'manage_sites_action_links', array_filter( $actions ), $blog['blog_id'], $blogname ); return $this->row_actions( $actions ); diff --git a/src/wp-admin/includes/class-wp-ms-themes-list-table.php b/src/wp-admin/includes/class-wp-ms-themes-list-table.php index ea6969f51c..36a0743bd3 100644 --- a/src/wp-admin/includes/class-wp-ms-themes-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-themes-list-table.php @@ -97,7 +97,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $all An array of WP_Theme objects to display in the list table. + * @param WP_Theme[] $all Array of WP_Theme objects to display in the list table. */ 'all' => apply_filters( 'all_themes', wp_get_themes() ), 'search' => array(), @@ -506,7 +506,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table { * * @since 2.8.0 * - * @param array $actions An array of action links. + * @param string[] $actions An array of action links. * @param WP_Theme $theme The current WP_Theme object. * @param string $context Status of the theme, one of 'all', 'enabled', or 'disabled'. */ @@ -522,7 +522,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $actions An array of action links. + * @param string[] $actions An array of action links. * @param WP_Theme $theme The current WP_Theme object. * @param string $context Status of the theme, one of 'all', 'enabled', or 'disabled'. */ @@ -587,7 +587,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $theme_meta An array of the theme's metadata, + * @param string[] $theme_meta An array of the theme's metadata, * including the version, author, and * theme URI. * @param string $stylesheet Directory name of the theme. diff --git a/src/wp-admin/includes/class-wp-ms-users-list-table.php b/src/wp-admin/includes/class-wp-ms-users-list-table.php index 1c2eaf07e2..eb507dafac 100644 --- a/src/wp-admin/includes/class-wp-ms-users-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-users-list-table.php @@ -178,8 +178,8 @@ class WP_MS_Users_List_Table extends WP_List_Table { * * @since MU (3.0.0) * - * @param array $users_columns An array of user columns. Default 'cb', 'username', - * 'name', 'email', 'registered', 'blogs'. + * @param string[] $users_columns An array of user columns. Default 'cb', 'username', + * 'name', 'email', 'registered', 'blogs'. */ return apply_filters( 'wpmu_users_columns', $users_columns ); } @@ -368,9 +368,8 @@ class WP_MS_Users_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $actions An array of action links to be displayed. - * Default 'Edit', 'View'. - * @param int $userblog_id The site ID. + * @param string[] $actions An array of action links to be displayed. Default 'Edit', 'View'. + * @param int $userblog_id The site ID. */ $actions = apply_filters( 'ms_user_list_site_actions', $actions, $val->userblog_id ); @@ -465,9 +464,8 @@ class WP_MS_Users_List_Table extends WP_List_Table { * * @since 3.2.0 * - * @param array $actions An array of action links to be displayed. - * Default 'Edit', 'Delete'. - * @param WP_User $user WP_User object. + * @param string[] $actions An array of action links to be displayed. Default 'Edit', 'Delete'. + * @param WP_User $user WP_User object. */ $actions = apply_filters( 'ms_user_row_actions', $actions, $user ); return $this->row_actions( $actions ); diff --git a/src/wp-admin/includes/class-wp-plugin-install-list-table.php b/src/wp-admin/includes/class-wp-plugin-install-list-table.php index 07ee266e09..f82a42b4a8 100644 --- a/src/wp-admin/includes/class-wp-plugin-install-list-table.php +++ b/src/wp-admin/includes/class-wp-plugin-install-list-table.php @@ -121,8 +121,8 @@ class WP_Plugin_Install_List_Table extends WP_List_Table { * * @since 2.7.0 * - * @param array $tabs The tabs shown on the Plugin Install screen. Defaults include 'featured', 'popular', - * 'recommended', 'favorites', and 'upload'. + * @param string[] $tabs The tabs shown on the Plugin Install screen. Defaults include 'featured', 'popular', + * 'recommended', 'favorites', and 'upload'. */ $tabs = apply_filters( 'install_plugins_tabs', $tabs ); @@ -131,7 +131,7 @@ class WP_Plugin_Install_List_Table extends WP_List_Table { * * @since 2.7.0 * - * @param array $nonmenu_tabs The tabs that don't have a Menu item on the Plugin Install screen. + * @param string[] $nonmenu_tabs The tabs that don't have a menu item on the Plugin Install screen. */ $nonmenu_tabs = apply_filters( 'install_plugins_nonmenu_tabs', $nonmenu_tabs ); @@ -602,8 +602,8 @@ class WP_Plugin_Install_List_Table extends WP_List_Table { * * @since 2.7.0 * - * @param array $action_links An array of plugin action hyperlinks. Defaults are links to Details and Install Now. - * @param array $plugin The plugin currently being listed. + * @param string[] $action_links An array of plugin action links. Defaults are links to Details and Install Now. + * @param array $plugin The plugin currently being listed. */ $action_links = apply_filters( 'plugin_install_action_links', $action_links, $plugin ); diff --git a/src/wp-admin/includes/class-wp-plugins-list-table.php b/src/wp-admin/includes/class-wp-plugins-list-table.php index 959c4e96ab..6e130f94b4 100644 --- a/src/wp-admin/includes/class-wp-plugins-list-table.php +++ b/src/wp-admin/includes/class-wp-plugins-list-table.php @@ -670,12 +670,12 @@ class WP_Plugins_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $actions An array of plugin action links. By default this can include 'activate', - * 'deactivate', and 'delete'. - * @param string $plugin_file Path to the plugin file relative to the plugins directory. - * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. - * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', - * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. + * @param string[] $actions An array of plugin action links. By default this can include 'activate', + * 'deactivate', and 'delete'. + * @param string $plugin_file Path to the plugin file relative to the plugins directory. + * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. + * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', + * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. */ $actions = apply_filters( 'network_admin_plugin_action_links', $actions, $plugin_file, $plugin_data, $context ); @@ -687,12 +687,12 @@ class WP_Plugins_List_Table extends WP_List_Table { * * @since 3.1.0 * - * @param array $actions An array of plugin action links. By default this can include 'activate', - * 'deactivate', and 'delete'. - * @param string $plugin_file Path to the plugin file relative to the plugins directory. - * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. - * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', - * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. + * @param string[] $actions An array of plugin action links. By default this can include 'activate', + * 'deactivate', and 'delete'. + * @param string $plugin_file Path to the plugin file relative to the plugins directory. + * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. + * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', + * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. */ $actions = apply_filters( "network_admin_plugin_action_links_{$plugin_file}", $actions, $plugin_file, $plugin_data, $context ); @@ -705,13 +705,13 @@ class WP_Plugins_List_Table extends WP_List_Table { * @since 2.6.0 The `$context` parameter was added. * @since 4.9.0 The 'Edit' link was removed from the list of action links. * - * @param array $actions An array of plugin action links. By default this can include 'activate', - * 'deactivate', and 'delete'. With Multisite active this can also include - * 'network_active' and 'network_only' items. - * @param string $plugin_file Path to the plugin file relative to the plugins directory. - * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. - * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', - * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. + * @param string[] $actions An array of plugin action links. By default this can include 'activate', + * 'deactivate', and 'delete'. With Multisite active this can also include + * 'network_active' and 'network_only' items. + * @param string $plugin_file Path to the plugin file relative to the plugins directory. + * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. + * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', + * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. */ $actions = apply_filters( 'plugin_action_links', $actions, $plugin_file, $plugin_data, $context ); @@ -724,13 +724,13 @@ class WP_Plugins_List_Table extends WP_List_Table { * @since 2.7.0 * @since 4.9.0 The 'Edit' link was removed from the list of action links. * - * @param array $actions An array of plugin action links. By default this can include 'activate', - * 'deactivate', and 'delete'. With Multisite active this can also include - * 'network_active' and 'network_only' items. - * @param string $plugin_file Path to the plugin file relative to the plugins directory. - * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. - * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', - * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. + * @param string[] $actions An array of plugin action links. By default this can include 'activate', + * 'deactivate', and 'delete'. With Multisite active this can also include + * 'network_active' and 'network_only' items. + * @param string $plugin_file Path to the plugin file relative to the plugins directory. + * @param array $plugin_data An array of plugin data. See `get_plugin_data()`. + * @param string $context The plugin context. By default this can include 'all', 'active', 'inactive', + * 'recently_activated', 'upgrade', 'mustuse', 'dropins', and 'search'. */ $actions = apply_filters( "plugin_action_links_{$plugin_file}", $actions, $plugin_file, $plugin_data, $context ); @@ -824,14 +824,14 @@ class WP_Plugins_List_Table extends WP_List_Table { * * @since 2.8.0 * - * @param array $plugin_meta An array of the plugin's metadata, - * including the version, author, - * author URI, and plugin URI. - * @param string $plugin_file Path to the plugin file relative to the plugins directory. - * @param array $plugin_data An array of plugin data. - * @param string $status Status of the plugin. Defaults are 'All', 'Active', - * 'Inactive', 'Recently Activated', 'Upgrade', 'Must-Use', - * 'Drop-ins', 'Search'. + * @param string[] $plugin_meta An array of the plugin's metadata, + * including the version, author, + * author URI, and plugin URI. + * @param string $plugin_file Path to the plugin file relative to the plugins directory. + * @param array $plugin_data An array of plugin data. + * @param string $status Status of the plugin. Defaults are 'All', 'Active', + * 'Inactive', 'Recently Activated', 'Upgrade', 'Must-Use', + * 'Drop-ins', 'Search'. */ $plugin_meta = apply_filters( 'plugin_row_meta', $plugin_meta, $plugin_file, $plugin_data, $status ); echo implode( ' | ', $plugin_meta ); diff --git a/src/wp-admin/includes/class-wp-posts-list-table.php b/src/wp-admin/includes/class-wp-posts-list-table.php index a09d76c4e4..671b8f2917 100644 --- a/src/wp-admin/includes/class-wp-posts-list-table.php +++ b/src/wp-admin/includes/class-wp-posts-list-table.php @@ -233,9 +233,9 @@ class WP_Posts_List_Table extends WP_List_Table { * * @since 4.4.0 * - * @param array $args URL parameters for the link. - * @param string $label Link text. - * @param string $class Optional. Class attribute. Default empty string. + * @param string[] $args Associative array of URL parameters for the link. + * @param string $label Link text. + * @param string $class Optional. Class attribute. Default empty string. * @return string The formatted link string. */ protected function get_edit_link( $args, $label, $class = '' ) { @@ -557,8 +557,8 @@ if ( $this->is_trash && current_user_can( get_post_type_object( $this->screen->p * * @since 3.5.0 * - * @param array $taxonomies Array of taxonomies to show columns for. - * @param string $post_type The post type. + * @param string[] $taxonomies Array of taxonomy names to show columns for. + * @param string $post_type The post type. */ $taxonomies = apply_filters( "manage_taxonomies_for_{$post_type}_columns", $taxonomies, $post_type ); $taxonomies = array_filter( $taxonomies, 'taxonomy_exists' ); @@ -589,7 +589,7 @@ if ( $this->is_trash && current_user_can( get_post_type_object( $this->screen->p * * @since 2.5.0 * - * @param array $post_columns An array of column names. + * @param string[] $post_columns An associative array of column headings. */ $posts_columns = apply_filters( 'manage_pages_columns', $posts_columns ); } else { @@ -599,8 +599,8 @@ if ( $this->is_trash && current_user_can( get_post_type_object( $this->screen->p * * @since 1.5.0 * - * @param array $posts_columns An array of column names. - * @param string $post_type The post type slug. + * @param string[] $post_columns An associative array of column headings. + * @param string $post_type The post type slug. */ $posts_columns = apply_filters( 'manage_posts_columns', $posts_columns, $post_type ); } @@ -612,7 +612,7 @@ if ( $this->is_trash && current_user_can( get_post_type_object( $this->screen->p * * @since 3.0.0 * - * @param array $post_columns An array of column names. + * @param string[] $post_columns An associative array of column headings. */ return apply_filters( "manage_{$post_type}_posts_columns", $posts_columns ); } @@ -1335,10 +1335,10 @@ if ( $this->is_trash && current_user_can( get_post_type_object( $this->screen->p * * @since 2.8.0 * - * @param array $actions An array of row action links. Defaults are - * 'Edit', 'Quick Edit', 'Restore', 'Trash', - * 'Delete Permanently', 'Preview', and 'View'. - * @param WP_Post $post The post object. + * @param string[] $actions An array of row action links. Defaults are + * 'Edit', 'Quick Edit', 'Restore', 'Trash', + * 'Delete Permanently', 'Preview', and 'View'. + * @param WP_Post $post The post object. */ $actions = apply_filters( 'page_row_actions', $actions, $post ); } else { @@ -1350,10 +1350,10 @@ if ( $this->is_trash && current_user_can( get_post_type_object( $this->screen->p * * @since 2.8.0 * - * @param array $actions An array of row action links. Defaults are - * 'Edit', 'Quick Edit', 'Restore', 'Trash', - * 'Delete Permanently', 'Preview', and 'View'. - * @param WP_Post $post The post object. + * @param string[] $actions An array of row action links. Defaults are + * 'Edit', 'Quick Edit', 'Restore', 'Trash', + * 'Delete Permanently', 'Preview', and 'View'. + * @param WP_Post $post The post object. */ $actions = apply_filters( 'post_row_actions', $actions, $post ); } diff --git a/src/wp-admin/includes/class-wp-screen.php b/src/wp-admin/includes/class-wp-screen.php index d4b5a9c92f..8e8499026a 100644 --- a/src/wp-admin/includes/class-wp-screen.php +++ b/src/wp-admin/includes/class-wp-screen.php @@ -1222,8 +1222,8 @@ if ( $this->show_screen_options() ) : * * @since 4.4.0 * - * @param array $view_mode_post_types Array of post types that can change view modes. - * Default non-hierarchical post types with show_ui on. + * @param string[] $view_mode_post_types Array of post types that can change view modes. + * Default non-hierarchical post types with show_ui on. */ $view_mode_post_types = apply_filters( 'view_mode_post_types', $view_mode_post_types ); diff --git a/src/wp-admin/includes/class-wp-site-icon.php b/src/wp-admin/includes/class-wp-site-icon.php index 47c48572f3..69ac09b408 100644 --- a/src/wp-admin/includes/class-wp-site-icon.php +++ b/src/wp-admin/includes/class-wp-site-icon.php @@ -34,7 +34,7 @@ class WP_Site_Icon { * List of site icon sizes. * * @since 4.3.0 - * @var array + * @var int[] */ public $site_icon_sizes = array( /* @@ -131,12 +131,12 @@ class WP_Site_Icon { } /** - * Adds additional sizes to be made when creating the site_icon images. + * Adds additional sizes to be made when creating the site icon images. * * @since 4.3.0 * - * @param array $sizes List of additional sizes. - * @return array Additional image sizes. + * @param array[] $sizes Array of arrays containing information for additional sizes. + * @return array[] Array of arrays containing additional image sizes. */ public function additional_sizes( $sizes = array() ) { $only_crop_sizes = array(); @@ -146,7 +146,7 @@ class WP_Site_Icon { * * @since 4.3.0 * - * @param array $site_icon_sizes Sizes available for the Site Icon. + * @param int[] $site_icon_sizes Array of sizes available for the Site Icon. */ $this->site_icon_sizes = apply_filters( 'site_icon_image_sizes', $this->site_icon_sizes ); @@ -179,8 +179,8 @@ class WP_Site_Icon { * * @since 4.3.0 * - * @param array $sizes List of image sizes. - * @return array List of intermediate image sizes. + * @param string[] $sizes Array of image size names. + * @return string[] Array of image size names. */ public function intermediate_image_sizes( $sizes = array() ) { /** This filter is documented in wp-admin/includes/class-wp-site-icon.php */ diff --git a/src/wp-admin/includes/class-wp-terms-list-table.php b/src/wp-admin/includes/class-wp-terms-list-table.php index 6ca1447f33..f7dacdd13a 100644 --- a/src/wp-admin/includes/class-wp-terms-list-table.php +++ b/src/wp-admin/includes/class-wp-terms-list-table.php @@ -486,9 +486,9 @@ class WP_Terms_List_Table extends WP_List_Table { * @since 2.8.0 * @deprecated 3.0.0 Use {$taxonomy}_row_actions instead. * - * @param array $actions An array of action links to be displayed. Default - * 'Edit', 'Quick Edit', 'Delete', and 'View'. - * @param WP_Term $tag Term object. + * @param string[] $actions An array of action links to be displayed. Default + * 'Edit', 'Quick Edit', 'Delete', and 'View'. + * @param WP_Term $tag Term object. */ $actions = apply_filters( 'tag_row_actions', $actions, $tag ); @@ -499,9 +499,9 @@ class WP_Terms_List_Table extends WP_List_Table { * * @since 3.0.0 * - * @param array $actions An array of action links to be displayed. Default - * 'Edit', 'Quick Edit', 'Delete', and 'View'. - * @param WP_Term $tag Term object. + * @param string[] $actions An array of action links to be displayed. Default + * 'Edit', 'Quick Edit', 'Delete', and 'View'. + * @param WP_Term $tag Term object. */ $actions = apply_filters( "{$taxonomy}_row_actions", $actions, $tag ); diff --git a/src/wp-admin/includes/class-wp-theme-install-list-table.php b/src/wp-admin/includes/class-wp-theme-install-list-table.php index a1ac60b628..938dab4cf3 100644 --- a/src/wp-admin/includes/class-wp-theme-install-list-table.php +++ b/src/wp-admin/includes/class-wp-theme-install-list-table.php @@ -76,8 +76,8 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table { * * @since 2.8.0 * - * @param array $nonmenu_tabs The tabs that don't have a menu item on - * the Install Themes screen. + * @param string[] $nonmenu_tabs The tabs that don't have a menu item on + * the Install Themes screen. */ $nonmenu_tabs = apply_filters( 'install_themes_nonmenu_tabs', $nonmenu_tabs ); @@ -334,7 +334,7 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table { * * @since 3.4.0 * - * @param array $actions An array of theme action hyperlinks. Defaults are + * @param string[] $actions An array of theme action links. Defaults are * links to Install Now, Preview, and Details. * @param WP_Theme $theme Theme object. */ diff --git a/src/wp-admin/includes/class-wp-users-list-table.php b/src/wp-admin/includes/class-wp-users-list-table.php index 90e244208c..a8de2904be 100644 --- a/src/wp-admin/includes/class-wp-users-list-table.php +++ b/src/wp-admin/includes/class-wp-users-list-table.php @@ -452,10 +452,10 @@ class WP_Users_List_Table extends WP_List_Table { * * @since 2.8.0 * - * @param array $actions An array of action links to be displayed. - * Default 'Edit', 'Delete' for single site, and - * 'Edit', 'Remove' for Multisite. - * @param WP_User $user_object WP_User object for the currently-listed user. + * @param string[] $actions An array of action links to be displayed. + * Default 'Edit', 'Delete' for single site, and + * 'Edit', 'Remove' for Multisite. + * @param WP_User $user_object WP_User object for the currently listed user. */ $actions = apply_filters( 'user_row_actions', $actions, $user_object ); @@ -571,7 +571,7 @@ class WP_Users_List_Table extends WP_List_Table { * @since 4.4.0 * * @param WP_User $user_object The WP_User object. - * @return array An array of user roles. + * @return string[] An array of user roles. */ protected function get_role_list( $user_object ) { $wp_roles = wp_roles(); @@ -593,8 +593,8 @@ class WP_Users_List_Table extends WP_List_Table { * * @since 4.4.0 * - * @param array $role_list An array of user roles. - * @param WP_User $user_object A WP_User object. + * @param string[] $role_list An array of user roles. + * @param WP_User $user_object A WP_User object. */ return apply_filters( 'get_role_list', $role_list, $user_object ); } diff --git a/src/wp-includes/media.php b/src/wp-includes/media.php index 614497a46b..a52048f475 100644 --- a/src/wp-includes/media.php +++ b/src/wp-includes/media.php @@ -2899,17 +2899,16 @@ function get_attachment_taxonomies( $attachment, $output = 'names' ) { } /** - * Retrieves all of the taxonomy names that are registered for attachments. + * Retrieves all of the taxonomies that are registered for attachments. * * Handles mime-type-specific taxonomies such as attachment:image and attachment:video. * * @since 3.5.0 - * * @see get_taxonomies() * * @param string $output Optional. The type of taxonomy output to return. Accepts 'names' or 'objects'. * Default 'names'. - * @return array The names of all taxonomy of $object_type. + * @return string[]|WP_Taxonomy[] Array of names or objects of registered taxonomies for attachments. */ function get_taxonomies_for_attachments( $output = 'names' ) { $taxonomies = array(); diff --git a/src/wp-includes/taxonomy.php b/src/wp-includes/taxonomy.php index 23a274f1ca..df828b0fc9 100644 --- a/src/wp-includes/taxonomy.php +++ b/src/wp-includes/taxonomy.php @@ -178,7 +178,7 @@ function create_initial_taxonomies() { * @param string $operator Optional. The logical operation to perform. Accepts 'and' or 'or'. 'or' means only * one element from the array needs to match; 'and' means all elements must match. * Default 'and'. - * @return array A list of taxonomy names or objects. + * @return string[]|WP_Taxonomy[] An array of taxonomy names or objects. */ function get_taxonomies( $args = array(), $output = 'names', $operator = 'and' ) { global $wp_taxonomies; diff --git a/src/wp-includes/theme.php b/src/wp-includes/theme.php index 564085a0b1..2a2922950d 100644 --- a/src/wp-includes/theme.php +++ b/src/wp-includes/theme.php @@ -28,7 +28,7 @@ * @type int $blog_id (Multisite) The blog ID used to calculate which themes are allowed. * Defaults to 0, synonymous for the current blog. * } - * @return array Array of WP_Theme objects. + * @return WP_Theme[] Array of WP_Theme objects. */ function wp_get_themes( $args = array() ) { global $wp_theme_directories; diff --git a/src/wp-includes/update.php b/src/wp-includes/update.php index 2bcf838497..efb97002c0 100644 --- a/src/wp-includes/update.php +++ b/src/wp-includes/update.php @@ -600,7 +600,7 @@ function wp_maybe_auto_update() { * * @since 3.7.0 * - * @return array + * @return object[] Array of translation objects that have available updates. */ function wp_get_translation_updates() { $updates = array();