Make action=query&list=users use User::getRights()
authorHoo man <hoo@online.de>
Tue, 11 Sep 2012 23:45:35 +0000 (01:45 +0200)
committerCatrope <roan.kattouw@gmail.com>
Thu, 25 Oct 2012 03:16:06 +0000 (20:16 -0700)
commitd05ddf6e0649c843d4314b292102011d46e0ba08
treef4e7e0c4255f9b5aab5afcd23060186370a77e7c
parent881c1d30e418ebf85c24ae739ed22de397634932
Make action=query&list=users use User::getRights()

Made action=query&list=users use User::getRights() if
usprop rights given. This not only removes redundant
code, but makes it execute the UserGetRights hook, so
that this now includes rights given by Extensions (eg.
CentralAuth does that).

Patch Set 2: Modified the User class to be able to
inject further data into User::newFromRow() and using
that to inject the groups taken out of one SQL query
(for performance reasons). Furthermore I've split up
the query in ApiQueryUsers.php into one for user data
and one for the groups, to only have one row for each
user.
After all the perfomance of this should now be ok, not
extremly good, but bearable (though I couldn't test it
deeply, as I don't have much data in my CentralAuth
environment).

Change-Id: Ie5b2924abb82ac254c77e1d04cc4d5b308962dad
includes/User.php
includes/api/ApiQueryUsers.php