Comments: Remove bulk action dropdown depending on user caps.

This changeset introduces the `manage_users-network_custom_column` filter that fires for each custom column in the Network Users list table. This is an override hook for `manage_users_custom_column` which was already filtering each custom column in all Users list tables.

Props lenasterg, realloc, audrasjb.
Fixes #43318.


Built from https://develop.svn.wordpress.org/trunk@59878


git-svn-id: http://core.svn.wordpress.org/trunk@59220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
audrasjb 2025-02-27 00:09:23 +00:00
parent 2574278658
commit 201731789c
2 changed files with 13 additions and 2 deletions

View File

@ -467,7 +467,18 @@ class WP_MS_Users_List_Table extends WP_List_Table {
$user = $item;
/** This filter is documented in wp-admin/includes/class-wp-users-list-table.php */
echo apply_filters( 'manage_users_custom_column', '', $column_name, $user->ID );
$column_output = apply_filters( 'manage_users_custom_column', '', $column_name, $user->ID );
/**
* Filters the display output of custom columns in the Network Users list table.
*
* @since 6.8.0
*
* @param string $output Custom column output. Default empty.
* @param string $column_name Name of the custom column.
* @param int $user_id ID of the currently-listed user.
*/
echo apply_filters( 'manage_users-network_custom_column', $column_output, $column_name, $user->ID );
}
/**

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.8-alpha-59877';
$wp_version = '6.8-alpha-59878';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.