Skip to content

Commit 1a7da55

Browse files
committed
Docs: Add missing @global descriptions and refine parameter documentations in wp-admin/includes classes.
Developed in #10931 Follow-up to [61638]. Props noruzzaman, huzaifaalmesbah, westonruter. See #64224. git-svn-id: https://develop.svn.wordpress.org/trunk@61657 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 297771e commit 1a7da55

4 files changed

Lines changed: 15 additions & 10 deletions

File tree

src/wp-admin/includes/class-wp-debug-data.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1132,7 +1132,7 @@ private static function get_wp_plugins_raw_data(): array {
11321132
*
11331133
* @since 6.7.0
11341134
*
1135-
* @global array $_wp_theme_features
1135+
* @global array<string, bool|array> $_wp_theme_features The theme features for the active theme.
11361136
*
11371137
* @return array<string, string|array> The active theme debug data.
11381138
*/

src/wp-admin/includes/class-wp-importer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ public function min_whitespace( $text ) {
279279
* @since 3.0.0
280280
*
281281
* @global wpdb $wpdb WordPress database abstraction object.
282-
* @global int[] $wp_actions
282+
* @global int[] $wp_actions Stores the number of times each action was triggered.
283283
*/
284284
public function stop_the_insanity() {
285285
global $wpdb, $wp_actions;

src/wp-admin/includes/class-wp-links-list-table.php

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ public function ajax_user_can() {
4242
}
4343

4444
/**
45-
* @global int $cat_id
46-
* @global string $s
47-
* @global string $orderby
48-
* @global string $order
45+
* @global int $cat_id Link category ID.
46+
* @global string $s Search string.
47+
* @global string $orderby The field to order the links by.
48+
* @global string $order The direction to order the links.
4949
*/
5050
public function prepare_items() {
5151
global $cat_id, $s, $orderby, $order;
@@ -77,12 +77,15 @@ public function prepare_items() {
7777
}
7878

7979
/**
80+
* Displays the message for no items.
8081
*/
8182
public function no_items() {
8283
_e( 'No links found.' );
8384
}
8485

8586
/**
87+
* Gets the list of bulk actions.
88+
*
8689
* @return array
8790
*/
8891
protected function get_bulk_actions() {
@@ -93,8 +96,8 @@ protected function get_bulk_actions() {
9396
}
9497

9598
/**
96-
* @global int $cat_id
97-
* @param string $which
99+
* @global int $cat_id Link category ID.
100+
* @param string $which The location: 'top' or 'bottom'.
98101
*/
99102
protected function extra_tablenav( $which ) {
100103
global $cat_id;
@@ -142,6 +145,8 @@ public function get_columns() {
142145
}
143146

144147
/**
148+
* Gets the list of sortable columns.
149+
*
145150
* @return array
146151
*/
147152
protected function get_sortable_columns() {
@@ -224,7 +229,7 @@ public function column_url( $link ) {
224229
*
225230
* @since 4.3.0
226231
*
227-
* @global int $cat_id
232+
* @global int $cat_id Link category ID.
228233
*
229234
* @param object $link The current link object.
230235
*/

src/wp-admin/includes/class-wp-list-table.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1692,7 +1692,7 @@ protected function display_tablenav( $which ) {
16921692
*
16931693
* @since 3.1.0
16941694
*
1695-
* @param string $which
1695+
* @param string $which The location: 'top' or 'bottom'.
16961696
*/
16971697
protected function extra_tablenav( $which ) {}
16981698

0 commit comments

Comments
 (0)