mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-16 19:46:21 +00:00
Show admin bar in single site backend by default. Props dimadin. fixes #17899
git-svn-id: http://svn.automattic.com/wordpress/trunk@18451 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
db8c49d886
commit
2564e26011
@ -442,7 +442,7 @@ function is_admin_bar_showing() {
|
|||||||
function _get_admin_bar_pref( $context, $user = 0 ) {
|
function _get_admin_bar_pref( $context, $user = 0 ) {
|
||||||
$pref = get_user_option( "show_admin_bar_{$context}", $user );
|
$pref = get_user_option( "show_admin_bar_{$context}", $user );
|
||||||
if ( false === $pref )
|
if ( false === $pref )
|
||||||
return 'admin' != $context || is_multisite();
|
return true;
|
||||||
|
|
||||||
return 'true' === $pref;
|
return 'true' === $pref;
|
||||||
}
|
}
|
||||||
|
@ -1463,7 +1463,7 @@ function wp_insert_user($userdata) {
|
|||||||
$show_admin_bar_front = 'true';
|
$show_admin_bar_front = 'true';
|
||||||
|
|
||||||
if ( empty($show_admin_bar_admin) )
|
if ( empty($show_admin_bar_admin) )
|
||||||
$show_admin_bar_admin = is_multisite() ? 'true' : 'false';
|
$show_admin_bar_admin = 'true';
|
||||||
|
|
||||||
$user_nicename_check = $wpdb->get_var( $wpdb->prepare("SELECT ID FROM $wpdb->users WHERE user_nicename = %s AND user_login != %s LIMIT 1" , $user_nicename, $user_login));
|
$user_nicename_check = $wpdb->get_var( $wpdb->prepare("SELECT ID FROM $wpdb->users WHERE user_nicename = %s AND user_login != %s LIMIT 1" , $user_nicename, $user_login));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user