Merge "Check requirements for parser test suite in phpunit tests"
[lhc/web/wiklou.git] / includes / specials / pagers / ActiveUsersPager.php
index e2f4d4b..64af71a 100644 (file)
@@ -1,7 +1,5 @@
 <?php
 /**
- * Copyright © 2008 Aaron Schulz
- *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
@@ -120,16 +118,15 @@ class ActiveUsersPager extends UsersPager {
                                ) . ')';
                }
 
-               if ( $dbr->implicitGroupby() ) {
-                       $options = [ 'GROUP BY' => [ 'qcc_title' ] ];
-               } else {
-                       $options = [ 'GROUP BY' => [ 'user_name', 'user_id', 'qcc_title' ] ];
-               }
-
                return [
                        'tables' => $tables,
-                       'fields' => [ 'user_name', 'user_id', 'recentedits' => 'COUNT(*)', 'qcc_title' ],
-                       'options' => $options,
+                       'fields' => [
+                               'qcc_title',
+                               'user_name' => 'qcc_title',
+                               'user_id' => 'MAX(user_id)',
+                               'recentedits' => 'COUNT(*)'
+                       ],
+                       'options' => [ 'GROUP BY' => [ 'qcc_title' ] ],
                        'conds' => $conds
                ];
        }