Changeset 13270 for trunk/wp-includes/capabilities.php
- Timestamp:
- 02/21/2010 12:19:05 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/capabilities.php
r13034 r13270 723 723 } 724 724 725 // Multisite super admin has all caps by definition.726 if ( is_multisite() && is_super_admin() )727 return true;728 729 725 $args = array_slice( func_get_args(), 1 ); 730 726 $args = array_merge( array( $cap, $this->ID ), $args ); 731 727 $caps = call_user_func_array( 'map_meta_cap', $args ); 728 729 // Multisite super admin has all caps by definition, Unless specifically denied. 730 if ( is_multisite() && is_super_admin() ) { 731 if ( in_array('do_not_allow', $caps) ) 732 return false; 733 return true; 734 } 735 732 736 // Must have ALL requested caps 733 737 $capabilities = apply_filters( 'user_has_cap', $this->allcaps, $caps, $args ); … … 1028 1032 $current_user = wp_get_current_user(); 1029 1033 1030 if ( is_multisite() && is_super_admin() )1031 return true;1032 1033 1034 if ( empty( $current_user ) ) 1034 1035 return false;
Note: See TracChangeset
for help on using the changeset viewer.