Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: upgrader_process_complete

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
262           }
263
264           // Remove upgrade hooks which are not required for translation updates.
265           remove_action( 'upgrader_process_complete', array( 'Language_Pack_Upgrader', 'async_upgrade' ), 20 );
266           remove_action( 'upgrader_process_complete', 'wp_version_check' );
267           remove_action( 'upgrader_process_complete', 'wp_update_plugins' );
268           remove_action( 'upgrader_process_complete', 'wp_update_themes' );
269
270           /** This action is documented in wp-admin/includes/class-wp-upgrader.php */
271           do_action( 'upgrader_process_complete', $this, array(
272                'action'       => 'update',
273                'type'         => 'translation',
274                'bulk'         => true,
275                'translations' => $language_updates_results
276           ) );
277
278           // Re-add upgrade hooks.
279           add_action( 'upgrader_process_complete', array( 'Language_Pack_Upgrader', 'async_upgrade' ), 20 );
280           add_action( 'upgrader_process_complete', 'wp_version_check', 10, 0 );