From 9c8bf5984295bde1234a4fcc761b6cd9ea346858 Mon Sep 17 00:00:00 2001 From: Felix Arntz Date: Thu, 20 Apr 2017 00:27:42 +0000 Subject: [PATCH] Multisite: Add `$network_id` parameter to `wp_update_network_counts()`. After the `$network_id` parameter has been introduced for `wp_update_network_site_counts()` in [40484] and `wp_update_network_user_counts()` in [40485], the new parameter can now also be used on the wrapping function. Fixes #40386. See #38699. Built from https://develop.svn.wordpress.org/trunk@40486 git-svn-id: http://core.svn.wordpress.org/trunk@40362 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/ms-functions.php | 9 ++++++--- wp-includes/version.php | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/wp-includes/ms-functions.php b/wp-includes/ms-functions.php index e024789052..d209435fd3 100644 --- a/wp-includes/ms-functions.php +++ b/wp-includes/ms-functions.php @@ -2274,10 +2274,13 @@ function wp_schedule_update_network_counts() { * Update the network-wide counts for the current network. * * @since 3.1.0 + * @since 4.8.0 The $network_id parameter has been added. + * + * @param int|null $network_id ID of the network. Default is the current network. */ -function wp_update_network_counts() { - wp_update_network_user_counts(); - wp_update_network_site_counts(); +function wp_update_network_counts( $network_id = null ) { + wp_update_network_user_counts( $network_id ); + wp_update_network_site_counts( $network_id ); } /** diff --git a/wp-includes/version.php b/wp-includes/version.php index 6b9e9f4b88..9d9026d4aa 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.8-alpha-40485'; +$wp_version = '4.8-alpha-40486'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.