WordPress Core Automatic Updates: Remove an accidental closure which isn't supported in PHP 5.2. See #22704
git-svn-id: https://develop.svn.wordpress.org/trunk@25447 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
d06cb2443f
commit
3ec962dd56
@ -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
Block a user