Ticket #14708: set-role.diff
File set-role.diff, 520 bytes (added by , 13 years ago) |
---|
-
capabilities.php
604 604 function set_role( $role ) { 605 605 foreach ( (array) $this->roles as $oldrole ) 606 606 unset( $this->caps[$oldrole] ); 607 608 if ( 1 == count( $this->roles ) && $role == $this->roles[0] ) 609 return; 610 607 611 if ( !empty( $role ) ) { 608 612 $this->caps[$role] = true; 609 613 $this->roles = array( $role => true );