diff --git a/lib/ManualImageCrop.php b/lib/ManualImageCrop.php index a7b9466..f6f8ebe 100644 --- a/lib/ManualImageCrop.php +++ b/lib/ManualImageCrop.php @@ -211,7 +211,7 @@ public function cropImage() { //checks if the destination image file is present (if it's not, we want to create a new file, as the WordPress returns the original image instead of specific one) if ($dst_file == $src_file) { $attachmentData = wp_generate_attachment_metadata( $data['attachmentId'], $dst_file ); - + //overwrite with previous values $prevAttachmentData = wp_get_attachment_metadata($data['attachmentId']); if (isset($prevAttachmentData['micSelectedArea'])) { @@ -336,7 +336,7 @@ public function cropImage() { } // Generate Retina Image - if( isset( $data['make2x'] ) && $data['make2x'] === 'true' ) { + if( isset( $data['make2x'] ) && $data['make2x'] === true ) { $dst_w2x = $dst_w * 2; $dst_h2x = $dst_h * 2;