WordPress.org

Make WordPress Core

Changeset 16551


Ignore:
Timestamp:
11/23/2010 04:29:21 PM (9 years ago)
Author:
ryan
Message:

Make sure create_users is strippped from blog admins for multisite setups where add_new_users is not enabled. see #15357

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/capabilities.php

    r16422 r16551  
    986986        break;
    987987    case 'create_users':
    988         if ( !is_multisite() || is_super_admin() || get_site_option( 'add_new_users' ) )
     988        if ( !is_multisite() )
    989989            $caps[] = $cap;
     990        elseif ( is_super_admin() || get_site_option( 'add_new_users' ) )
     991            $caps[] = $cap;
     992        else
     993            $caps[] = 'do_not_allow';
    990994        break;
    991995    default:
Note: See TracChangeset for help on using the changeset viewer.