(bug 24987) Special:ListUsers does not take external groups into account. Patch by...
authorRoan Kattouw <catrope@users.mediawiki.org>
Sun, 12 Sep 2010 15:15:30 +0000 (15:15 +0000)
committerRoan Kattouw <catrope@users.mediawiki.org>
Sun, 12 Sep 2010 15:15:30 +0000 (15:15 +0000)
CREDITS
RELEASE-NOTES
includes/specials/SpecialListusers.php

diff --git a/CREDITS b/CREDITS
index 861f887..0ca55dd 100644 (file)
--- a/CREDITS
+++ b/CREDITS
@@ -102,6 +102,7 @@ following names for their contribution to the product.
 * Marcin Cieślak
 * Marcus Buck
 * Marooned
+* Mathias Ertl
 * Matthew Britton
 * mati
 * Max Sikström
index abbb8b3..710a7e6 100644 (file)
@@ -315,6 +315,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * (bug 6204) TOC not properly rendered when using $wgMaxTocLevel
 * (bug 24977) The accesskey in history page now lead directly to the diff 
   instead of alterning focus between the two buttons.
+* (bug 24987) Special:ListUsers does not take external groups into account
 
 === API changes in 1.17 ===
 * (bug 22738) Allow filtering by action type on query=logevent.
index 8d53f57..d959f5f 100644 (file)
@@ -125,13 +125,12 @@ class UsersPager extends AlphabeticPager {
                $userPage = Title::makeTitle( NS_USER, $row->user_name );
                $name = $this->getSkin()->link( $userPage, htmlspecialchars( $userPage->getText() ) );
 
-               if( $row->numgroups > 1 || ( $this->requestedGroup && $row->numgroups == 1 ) ) {
+               $groups_list = self::getGroups( $row->user_id );
+               if( count( $groups_list ) > 0 ) {
                        $list = array();
-                       foreach( self::getGroups( $row->user_id ) as $group )
+                       foreach( $groups_list as $group )
                                $list[] = self::buildGroupLink( $group );
                        $groups = $wgLang->commaList( $list );
-               } elseif( $row->numgroups == 1 ) {
-                       $groups = self::buildGroupLink( $row->singlegroup );
                } else {
                        $groups = '';
                }