Docs: Update hook docs for the `upgrader_package_options` filter and `upgrader_process_complete` action to reflect expected values in the core, language pack, theme, and plugin contexts.

Props nextendweb for the initial patch.
See [37550]. Fixes #36875.

Built from https://develop.svn.wordpress.org/trunk@37558


git-svn-id: http://core.svn.wordpress.org/trunk@37526 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Drew Jaynes 2016-05-25 14:45:27 +00:00
parent 294f2c98f1
commit 62d4798863
2 changed files with 22 additions and 10 deletions

View File

@ -651,6 +651,8 @@ class WP_Upgrader {
/**
* Filters the package options before running an update.
*
* See also {@see 'upgrader_process_complete'}.
*
* @since 4.3.0
*
* @param array $options {
@ -662,7 +664,18 @@ class WP_Upgrader {
* @type bool $clear_working Clear the working resource.
* @type bool $abort_if_destination_exists Abort if the Destination directory exists.
* @type bool $is_multi Whether the upgrader is running multiple times.
* @type array $hook_extra Extra hook arguments.
* @type array $hook_extra {
* Extra hook arguments.
*
* @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 string $plugin The base plugin path from the plugins directory.
* @type string $theme The stylesheet or template name of the theme.
* @type string $language_update_type The language pack update type. Accepts 'plugin', 'theme',
* or 'core'.
* @type object $language_update The language pack update offer.
* }
* }
*/
$options = apply_filters( 'upgrader_package_options', $options );
@ -745,6 +758,8 @@ class WP_Upgrader {
/**
* Fires when the upgrader process is complete.
*
* See also {@see 'upgrader_package_options'}.
*
* @since 3.6.0
* @since 3.7.0 Added to WP_Upgrader::run().
*
@ -753,14 +768,11 @@ class WP_Upgrader {
* @param array $hook_extra {
* 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 string $plugin The base plugin path from the plugins directory.
* @type string $theme The stylesheet or template name of the theme.
* @type string $language_update_type The language pack update type. Accepts 'plugin', 'theme',
* or 'core'.
* @type object $language_update The language pack update offer.
* @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 $plugins Array of the basename paths of the plugins' main files.
* @type array $themes The theme slugs.
* }
*/
do_action( 'upgrader_process_complete', $this, $options['hook_extra'] );

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.6-alpha-37557';
$wp_version = '4.6-alpha-37558';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.