Add an action, pre_get_users, in WP_User_Query::prepare_query().

Props rmccue.
Fixes #29084.


git-svn-id: https://develop.svn.wordpress.org/trunk@29363 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Scott Taylor 2014-08-02 20:45:07 +00:00
parent 6bac38232c
commit 6723459a79

View File

@ -523,6 +523,19 @@ class WP_User_Query {
) );
}
/**
* Fires before the WP_User_Query has been parsed.
*
* The passed WP_User_Query object contains the query variables, not
* yet passed into SQL.
*
* @since 4.0.0
*
* @param WP_User_Query $this The current WP_User_Query instance,
* passed by reference.
*/
do_action( 'pre_get_users', $this );
$qv =& $this->query_vars;
if ( is_array( $qv['fields'] ) ) {