From 6e9830f34d68252b25653d7db723bccae429416d Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Thu, 3 Jan 2013 05:23:36 +0000 Subject: [PATCH] Don't stomp existing sizes inside wp_save_image(). props markoheijnen. see #22985. for trunk. git-svn-id: https://develop.svn.wordpress.org/trunk@23246 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/image-edit.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-admin/includes/image-edit.php b/wp-admin/includes/image-edit.php index 3e3b180267..01bce7bd97 100644 --- a/wp-admin/includes/image-edit.php +++ b/wp-admin/includes/image-edit.php @@ -692,7 +692,7 @@ function wp_save_image( $post_id ) { $_sizes[ $size ] = array( 'width' => get_option("{$size}_size_w"), 'height' => get_option("{$size}_size_h"), 'crop' => $crop ); } - $meta['sizes'] = $img->multi_resize( $_sizes ); + $meta['sizes'] = array_merge( $meta['sizes'], $img->multi_resize( $_sizes ) ); } unset( $img );