From 0f47b70106812410dde3ef9fad10dab4378d1224 Mon Sep 17 00:00:00 2001 From: "Dominik Schilling (ocean90)" Date: Tue, 10 May 2016 12:19:18 +0000 Subject: [PATCH] Upgrader: After [37409] move the hook docs for `upgrader_process_complete` to `WP_Upgrader::run()`. Add changelog entry for [23912]. Part 7/8. See #36618. git-svn-id: https://develop.svn.wordpress.org/trunk@37412 602fd350-edb4-49c9-b593-d223f7449a82 --- .../includes/class-plugin-upgrader.php | 17 +---------------- src/wp-admin/includes/class-wp-upgrader.php | 18 +++++++++++++++++- 2 files changed, 18 insertions(+), 17 deletions(-) diff --git a/src/wp-admin/includes/class-plugin-upgrader.php b/src/wp-admin/includes/class-plugin-upgrader.php index 743fb797df..e2d9308d24 100644 --- a/src/wp-admin/includes/class-plugin-upgrader.php +++ b/src/wp-admin/includes/class-plugin-upgrader.php @@ -293,22 +293,7 @@ class Plugin_Upgrader extends WP_Upgrader { $this->maintenance_mode(false); - /** - * Fires when the bulk upgrader process is complete. - * - * @since 3.6.0 - * - * @param Plugin_Upgrader $this Plugin_Upgrader instance. In other contexts, $this, might - * be a Theme_Upgrader or Core_Upgrade instance. - * @param array $data { - * Array of bulk item update data. - * - * @type string $action Type of action. Default 'update'. - * @type string $type Type of update process. Accepts 'plugin', 'theme', or 'core'. - * @type bool $bulk Whether the update process is a bulk update. Default true. - * @type array $packages Array of plugin, theme, or core packages to update. - * } - */ + /** This action is documented in wp-admin/includes/class-wp-upgrader.php */ do_action( 'upgrader_process_complete', $this, array( 'action' => 'update', 'type' => 'plugin', diff --git a/src/wp-admin/includes/class-wp-upgrader.php b/src/wp-admin/includes/class-wp-upgrader.php index ac989d94cc..34709dd204 100644 --- a/src/wp-admin/includes/class-wp-upgrader.php +++ b/src/wp-admin/includes/class-wp-upgrader.php @@ -743,7 +743,23 @@ class WP_Upgrader { if ( ! $options['is_multi'] ) { - /** This action is documented in wp-admin/includes/class-wp-upgrader.php */ + /** + * Fires when the upgrader process is complete. + * + * @since 3.6.0 + * @since 3.7.0 Added to WP_Upgrader::run(). + * + * @param WP_Upgrader $this WP_Upgrader instance. In other contexts, $this, might be a + * Theme_Upgrader, Plugin_Upgrader or Core_Upgrade instance. + * @param array $data { + * Array of bulk item update data. + * + * @type string $action Type of action. Default 'update'. + * @type string $type Type of update process. Accepts 'plugin', 'theme', or 'core'. + * @type bool $bulk Whether the update process is a bulk update. Default true. + * @type array $packages Array of plugin, theme, or core packages to update. + * } + */ do_action( 'upgrader_process_complete', $this, $options['hook_extra'] ); $this->skin->footer(); }