Ticket #21120: 21120.5.diff
File 21120.5.diff, 634 bytes (added by , 12 years ago) |
---|
-
wp-includes/capabilities.php
1423 1423 * @return bool True if the user is a site admin. 1424 1424 */ 1425 1425 function is_super_admin( $user_id = false ) { 1426 if ( ! $user_id ) 1427 $user_id = get_current_user_id(); 1426 if ( ! $user_id || get_current_user_id() == $user_id ) 1427 $user = wp_get_current_user(); 1428 else 1429 $user = get_userdata( $user_id ); 1428 1430 1429 if ( ! $user = get_userdata( $user_id ))1431 if ( ! $user ) 1430 1432 return false; 1431 1433 1432 1434 if ( is_multisite() ) {