Make WordPress Core


Ignore:
Timestamp:
07/29/2010 09:54:41 PM (14 years ago)
Author:
nacin
Message:

Ensure we're checking when looking for is_super_admin() in map_meta_cap(). Bump DB version.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.0/wp-includes/capabilities.php

    r15403 r15478  
    813813    case 'edit_users':
    814814        // If multisite these caps are allowed only for super admins.
    815         if ( is_multisite() && !is_super_admin() )
     815        if ( is_multisite() && !is_super_admin( $user_id ) )
    816816            $caps[] = 'do_not_allow';
    817817        else
     
    992992        break;
    993993    case 'unfiltered_upload':
    994         if ( defined('ALLOW_UNFILTERED_UPLOADS') && ALLOW_UNFILTERED_UPLOADS && ( !is_multisite() || is_super_admin() )  )
     994        if ( defined('ALLOW_UNFILTERED_UPLOADS') && ALLOW_UNFILTERED_UPLOADS && ( !is_multisite() || is_super_admin( $user_id ) )  )
    995995            $caps[] = $cap;
    996996        else
     
    10291029    case 'delete_users':
    10301030        // If multisite these caps are allowed only for super admins.
    1031         if ( is_multisite() && !is_super_admin() )
     1031        if ( is_multisite() && !is_super_admin( $user_id ) )
    10321032            $caps[] = 'do_not_allow';
    10331033        else
Note: See TracChangeset for help on using the changeset viewer.