From 712855bf2d1a5de3a6d182fdd1e5efccc111b22a Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 10 Oct 2023 15:57:24 +0200 Subject: 🚑️ manage photos with altered bits (refs #5626) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ishtar_common/models.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'ishtar_common/models.py') diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 870dd41db..75e07d7cb 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -538,9 +538,10 @@ class ImageModel(models.Model, ImageContainerModel): self.thumbnail = None self.image = None finally: + returned = super().save(*args, **kwargs) if image: image.close() - return super(ImageModel, self).save(*args, **kwargs) + return returned def _get_thumb_name(self, filename): splited = filename.split(".") -- cgit v1.2.3