r79554 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r79553‎ | r79554 | r79555 >
Date:02:48, 4 January 2011
Author:reedy
Status:resolved
Tags:
Comment:
* (bug 26558) list=allusers auprop=groups does not list groups a user is automatically a member of
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/api/ApiQueryAllUsers.php (modified) (history)
  • /trunk/phase3/includes/api/ApiQueryUsers.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/api/ApiQueryAllUsers.php
@@ -201,6 +201,10 @@
202202
203203 // Add user's group info
204204 if ( $fld_groups && !is_null( $row->ug_group2 ) ) {
 205+ if ( !isset( $lastUserData['groups'] ) ) {
 206+ $lastUserData['groups'] = ApiQueryUsers::getAutoGroups( User::newFromName( $lastUser ) );
 207+ }
 208+
205209 $lastUserData['groups'][] = $row->ug_group2;
206210 $result->setIndexedTagName( $lastUserData['groups'], 'g' );
207211 }
Index: trunk/phase3/includes/api/ApiQueryUsers.php
@@ -229,6 +229,7 @@
230230
231231 /**
232232 * Gets all the groups that a user is automatically a member of
 233+ * @param $user User
233234 * @return array
234235 */
235236 public static function getAutoGroups( $user ) {
Index: trunk/phase3/RELEASE-NOTES
@@ -67,6 +67,7 @@
6868 * (bug 26541) Generator-ise ApiQueryRecentChanges
6969 * action=parse now correctly returns an error for nonexistent pages
7070 * (bug 25767) Add userrights properties to allusers and users query lists
 71+* (bug 26558) list=allusers auprop=groups does not list groups a user is automatically a member of
7172
7273 === Languages updated in 1.18 ===
7374

Follow-up revisions

RevisionCommit summaryAuthorDate
r84363Actually list implicit groups in allusers....reedy00:23, 20 March 2011

Status & tagging log