From 6a3638dc040ea02506b195685beb5e05d31194ec Mon Sep 17 00:00:00 2001 From: Jean-Paul Smets <jp@nexedi.com> Date: Mon, 18 Sep 2006 19:00:10 +0000 Subject: [PATCH] More fixes - now unit test passes git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@10127 20353a03-c40f-0410-a6d1-a30d3c3de9de --- product/ERP5Type/Utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/product/ERP5Type/Utils.py b/product/ERP5Type/Utils.py index 2033d92a32..03a049033c 100644 --- a/product/ERP5Type/Utils.py +++ b/product/ERP5Type/Utils.py @@ -353,8 +353,8 @@ class TempDocumentConstructor(DocumentConstructor): setattr(o, k, getattr(o,"_temp_%s" % k)) if kw: o.__of__(folder)._edit(force_update=1, **kw) - if folder.isTempObject(): # Temp Object in Temp Object should use containment - folder._setObject(id, o) + if hasattr(folder, 'isTempObject') and folder.isTempObject(): + folder._setObject(id, o)# Temp Object in Temp Object should use containment return id # return id to be compatible with CMF constructInstance else: # Temp Object in Persistent Object should use acquisition o = o.__of__(folder) -- 2.30.9