In WP_Users_List_Table::single_row()
, $actions
is not always set before being used.
See #33491. git-svn-id: https://develop.svn.wordpress.org/trunk@33735 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
3b8c5529cb
commit
ff7fcf5f04
@ -359,15 +359,14 @@ class WP_Users_List_Table extends WP_List_Table {
|
||||
else
|
||||
$url = 'users.php?';
|
||||
|
||||
// Set up the hover actions for this user
|
||||
$actions = array();
|
||||
$checkbox = '';
|
||||
// Check if the user for this row is editable
|
||||
if ( current_user_can( 'list_users' ) ) {
|
||||
// Set up the user editing link
|
||||
$edit_link = esc_url( add_query_arg( 'wp_http_referer', urlencode( wp_unslash( $_SERVER['REQUEST_URI'] ) ), get_edit_user_link( $user_object->ID ) ) );
|
||||
|
||||
// Set up the hover actions for this user
|
||||
$actions = array();
|
||||
|
||||
if ( current_user_can( 'edit_user', $user_object->ID ) ) {
|
||||
$edit = "<strong><a href=\"$edit_link\">$user_object->user_login</a></strong><br />";
|
||||
$actions['edit'] = '<a href="' . $edit_link . '">' . __( 'Edit' ) . '</a>';
|
||||
|
Loading…
Reference in New Issue
Block a user