summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2019-08-26 16:56:33 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2019-08-26 16:56:33 +0200
commitcfcba45d0afaba5854d23bdaf067e9cf47cdf99d (patch)
tree51c914dffcd998c2239bbac1935a0779b5ba380d
parent1c6ba3802f31a37b96700d83e74b41e896ebaa6e (diff)
downloadIshtar-cfcba45d0afaba5854d23bdaf067e9cf47cdf99d.tar.bz2
Ishtar-cfcba45d0afaba5854d23bdaf067e9cf47cdf99d.zip
Import: regression - M2M do not import with no value (defaults is not a value)
-rw-r--r--ishtar_common/data_importer.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ishtar_common/data_importer.py b/ishtar_common/data_importer.py
index 2680cb05b..b0e01d70d 100644
--- a/ishtar_common/data_importer.py
+++ b/ishtar_common/data_importer.py
@@ -1490,7 +1490,8 @@ class Importer(object):
if attribute not in new_created:
new_created[attribute] = []
new_created[attribute].append(key)
- has_values = bool([1 for k in v if v[k]])
+ has_values = bool([1 for k in v
+ if v[k] and k != "defaults"])
if has_values:
if self.MODEL_CREATION_LIMIT and \
model not in self.MODEL_CREATION_LIMIT: