Per the below, as User::getGroupsWithPermission() will return */autoconfirmed, etc if applicable
> var_dump( User::getGroupsWithPermission( 'createtalk' ) );
array(2) {
[0]=>
string(1) "*"
[1]=>
string(4) "user"
}
> var_dump( User::getGroupsWithPermission( 'autoconfirmed' ) );
array(5) {
[0]=>
string(13) "autoconfirmed"
[1]=>
string(3) "bot"
[2]=>
string(5) "sysop"
[3]=>
string(8) "reviewer"
[4]=>
string(9) "confirmed"
}
$groups = array_merge( $groups, User::getGroupsWithPermission( $r ) );
}
- $groups = array_diff( array_unique( $groups ), User::getImplicitGroups() );
+ $groups = array_unique( $groups );
if ( is_null( $params['group'] ) ) {
$params['group'] = $groups;
*/
protected static function getGroups( $uid ) {
$user = User::newFromId( $uid );
- $groups = array_diff( $user->getEffectiveGroups(), $user->getImplicitGroups() );
+ $groups = array_diff( $user->getEffectiveGroups(), User::getImplicitGroups() );
return $groups;
}