Make WordPress Core

Ticket #30394: 30394.diff

File 30394.diff, 627 bytes (added by wonderboymusic, 10 years ago)
  • wp-admin/includes/image-edit.php

     
    738738                if ( $tag )
    739739                        $backup_sizes[$tag] = array('width' => $meta['width'], 'height' => $meta['height'], 'file' => $path_parts['basename']);
    740740
    741                 $success = update_attached_file( $post_id, $new_path );
     741                if ( $path == $new_path ) {
     742                        $success = true;
     743                } else {
     744                        $success = update_attached_file( $post_id, $new_path );
     745                }
    742746
    743747                $meta['file'] = _wp_relative_upload_path( $new_path );
    744748