Changeset 25763 for trunk/src/wp-admin/includes/update-core.php
- Timestamp:
- 10/11/2013 04:05:13 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/update-core.php
r25658 r25763 662 662 if ( ! $wp_filesystem->copy( $from . $distro . 'wp-includes/version.php', $versions_file ) ) { 663 663 $wp_filesystem->delete( $from, true ); 664 return new WP_Error( 'copy_failed ', __('Could not copy file.') );664 return new WP_Error( 'copy_failed_for_version_file', __( 'Could not copy file.' ) ); 665 665 } 666 666 … … 742 742 743 743 // If we don't have enough free space, it isn't worth trying again 744 if ( $total_size >= disk_free_space( ABSPATH ) ) 744 if ( $total_size >= disk_free_space( ABSPATH ) ) { 745 745 $result = new WP_Error( 'disk_full', __( 'There is not enough free disk space to complete the update.' ), $to ); 746 else746 } else { 747 747 $result = _copy_dir( $from . $distro, $to, $skip ); 748 if ( is_wp_error( $result ) ) 749 $result = new WP_Error( $result->get_error_code() . '_retry', $result->get_error_message(), $result->get_error_data() ); 750 } 748 751 } 749 752 … … 801 804 802 805 if ( ! $wp_filesystem->copy($from . $distro . 'wp-content/' . $file, $dest . $filename, FS_CHMOD_FILE) ) 803 $result = new WP_Error( 'copy_failed', __('Could not copy file.'), $dest . $filename);806 $result = new WP_Error( 'copy_failed_for_new_bundled', __( 'Could not copy file.' ), $dest . $filename ); 804 807 } else { 805 808 if ( ! $development_build && $wp_filesystem->is_dir( $dest . $filename ) ) … … 888 891 $wp_filesystem->chmod($to . $filename, 0644); 889 892 if ( ! $wp_filesystem->copy($from . $filename, $to . $filename, true, FS_CHMOD_FILE) ) 890 return new WP_Error( 'copy_failed', __('Could not copy file.'), $to . $filename);893 return new WP_Error( 'copy_failed__copy_dir', __( 'Could not copy file.' ), $to . $filename ); 891 894 } 892 895 } elseif ( 'd' == $fileinfo['type'] ) { 893 896 if ( !$wp_filesystem->is_dir($to . $filename) ) { 894 897 if ( !$wp_filesystem->mkdir($to . $filename, FS_CHMOD_DIR) ) 895 return new WP_Error( 'mkdir_failed', __('Could not create directory.'), $to . $filename);898 return new WP_Error( 'mkdir_failed__copy_dir', __( 'Could not create directory.' ), $to . $filename ); 896 899 } 897 900
Note: See TracChangeset
for help on using the changeset viewer.