Use get_dashboard_url() to redirect to the active blog if the user doesn't have access to the current blog. fixes #16297

git-svn-id: https://develop.svn.wordpress.org/trunk@17367 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2011-01-26 16:35:04 +00:00
parent c4d608db4f
commit 900cee7dc9

View File

@ -588,7 +588,7 @@ default:
if ( is_multisite() && !get_active_blog_for_user($user->id) )
$redirect_to = user_admin_url();
elseif ( is_multisite() && !$user->has_cap('read') )
$redirect_to = user_admin_url();
$redirect_to = get_dashboard_url( $user->id );
elseif ( !$user->has_cap('edit_posts') )
$redirect_to = admin_url('profile.php');
}