mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
Multisite: Add a ms_sites_list_table_query_args
filter to WP_MS_Sites_List_Table
.
This allows a developer to filter the arguments used to query sites during the `prepare_items()` method. Props flixos90. Fixes #26580. Built from https://develop.svn.wordpress.org/trunk@37899 git-svn-id: http://core.svn.wordpress.org/trunk@37840 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
571f70c60a
commit
6d7bac459a
@ -158,6 +158,15 @@ class WP_MS_Sites_List_Table extends WP_List_Table {
|
|||||||
$args['no_found_rows'] = false;
|
$args['no_found_rows'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Filters the arguments for the site query in the sites list table.
|
||||||
|
*
|
||||||
|
* @since 4.6.0
|
||||||
|
*
|
||||||
|
* @param array $args An array of get_sites() arguments.
|
||||||
|
*/
|
||||||
|
$args = apply_filters( 'ms_sites_list_table_query_args', $args );
|
||||||
|
|
||||||
$_sites = get_sites( $args );
|
$_sites = get_sites( $args );
|
||||||
if ( is_array( $_sites ) ) {
|
if ( is_array( $_sites ) ) {
|
||||||
update_site_cache( $_sites );
|
update_site_cache( $_sites );
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.6-alpha-37898';
|
$wp_version = '4.6-alpha-37899';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
Loading…
Reference in New Issue
Block a user