WordPress Core Automatic Updates: Remove an accidental closure which isn't supported in PHP 5.2. See #22704
Built from https://develop.svn.wordpress.org/trunk@25447 git-svn-id: http://core.svn.wordpress.org/trunk@25368 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
1f507db1c0
commit
d39f430f64
|
@ -1370,15 +1370,13 @@ class WP_Automatic_Upgrader {
|
|||
|
||||
static function upgrade( $type, $item ) {
|
||||
|
||||
self::$skin = new Automatic_Upgrader_Skin();
|
||||
if ( ! self::$skin )
|
||||
self::$skin = new Automatic_Upgrader_Skin();
|
||||
|
||||
switch ( $type ) {
|
||||
case 'core':
|
||||
// The Core upgrader doesn't use the Upgrader's skin during the actual main part of the upgrade, instead, firing a filter
|
||||
add_filter( 'update_feedback', function( $message ) {
|
||||
WP_Background_Upgrader::$skin->feedback( $message );
|
||||
return $message;
|
||||
} );
|
||||
add_filter( 'update_feedback', array( self::$skin, 'feedback' ) );
|
||||
$upgrader = new Core_Upgrader( self::$skin );
|
||||
$context = ABSPATH;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue