Language Pack Upgrader: Remove any pre-existing package checks and then set the new one for translations.
fixes #29230. Built from https://develop.svn.wordpress.org/trunk@29621 git-svn-id: http://core.svn.wordpress.org/trunk@29395 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
3951d9689c
commit
5a67538b40
|
@ -1256,7 +1256,9 @@ class Language_Pack_Upgrader extends WP_Upgrader {
|
|||
if ( 'upgrader_process_complete' == current_filter() )
|
||||
$this->skin->feedback( 'starting_upgrade' );
|
||||
|
||||
add_filter( 'upgrader_source_selection', array( &$this, 'check_package' ), 10, 3 );
|
||||
// Remove any existing package checks and then set the new one for translations, #WP29230.
|
||||
remove_all_filters( 'upgrader_source_selection' );
|
||||
add_filter( 'upgrader_source_selection', array( $this, 'check_package' ), 10, 2 );
|
||||
|
||||
$this->skin->header();
|
||||
|
||||
|
@ -1320,7 +1322,7 @@ class Language_Pack_Upgrader extends WP_Upgrader {
|
|||
$this->skin->footer();
|
||||
|
||||
// Clean up our hooks, in case something else does an upgrade on this connection.
|
||||
remove_filter( 'upgrader_source_selection', array( &$this, 'check_package' ), 10, 2 );
|
||||
remove_filter( 'upgrader_source_selection', array( $this, 'check_package' ) );
|
||||
|
||||
if ( $parsed_args['clear_update_cache'] ) {
|
||||
wp_clean_themes_cache( true );
|
||||
|
|
Loading…
Reference in New Issue