From 38cc05cf37426f6def80f740fb8b7d1fdfe36a89 Mon Sep 17 00:00:00 2001 From: matthew Date: Thu, 4 Jul 2019 12:58:15 -0500 Subject: [PATCH] Fixed issue with merge's duplicate hash check --- ext/image/main.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/image/main.php b/ext/image/main.php index ff883c77..099bdd65 100644 --- a/ext/image/main.php +++ b/ext/image/main.php @@ -348,7 +348,8 @@ class ImageIO extends Extension } $duplicate = Image::by_hash($image->hash); - if(!is_null($duplicate)) { + + if(!is_null($duplicate) && $duplicate->id!=$id) { $error = "Image {$duplicate->id} " . "already has hash {$image->hash}:

" . $this->theme->build_thumb_html($duplicate); throw new ImageReplaceException($error);