summaryrefslogtreecommitdiff
path: root/ishtar_common/models.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2018-05-15 18:54:19 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2018-06-12 08:44:34 +0200
commit473dca5293f3a52acbf35ef9ff962c1ea8e031d1 (patch)
tree17a144f0d505f962db12ed91f113bab57e6ee27b /ishtar_common/models.py
parent02625b337570ff5cc53c00770c36cc14b12aa8b8 (diff)
downloadIshtar-473dca5293f3a52acbf35ef9ff962c1ea8e031d1.tar.bz2
Ishtar-473dca5293f3a52acbf35ef9ff962c1ea8e031d1.zip
Fix tests for M2M images
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r--ishtar_common/models.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py
index 97af69417..b4a385b4e 100644
--- a/ishtar_common/models.py
+++ b/ishtar_common/models.py
@@ -3183,7 +3183,8 @@ class IshtarImage(ImageModel):
super(IshtarImage, self).save(*args, **kwargs)
- if not no_path_change and not getattr(self, '_no_path_change', False):
+ if self.image and not no_path_change and \
+ not getattr(self, '_no_path_change', False):
links = self._move_image()
links = self.LINK_SPLIT.join(links)
if links != self.associated_links: