Make WordPress Core

Changeset 20619


Ignore:
Timestamp:
04/27/2012 06:57:59 PM (14 years ago)
Author:
nacin
Message:

Check if update_core() exists before calling it in Core_Upgrader. If not, issue an error message that the copy failed likely due to disk space. fixes #19883.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/class-wp-upgrader.php

    r20520 r20619  
    10221022                $this->strings['unpack_package'] = __('Unpacking the update…');
    10231023                $this->strings['copy_failed'] = __('Could not copy files.');
     1024                $this->strings['copy_failed_space'] = __('Could not copy files. You may have run out of disk space.' );
    10241025        }
    10251026
    … …  
    10741075                require(ABSPATH . 'wp-admin/includes/update-core.php');
    10751076
     1077                if ( ! function_exists( 'update_core' ) )
     1078                        return new WP_Error( 'copy_failed_space', $this->strings['copy_failed_space'] );
     1079
    10761080                return update_core($working_dir, $wp_dir);
    10771081        }
Note: See TracChangeset for help on using the changeset viewer.