From f22f1cfce6c6c4542526b2e3f99a85f7e8efa7de Mon Sep 17 00:00:00 2001
From: Nicolas Delaby <nicolas@nexedi.com>
Date: Fri, 7 May 2010 09:13:20 +0000
Subject: [PATCH] Temporary patch: Protect interaction for temporary objects as
 updateContentMd5 is useless for such kind of object

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35099 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../Document_updateContentMd5.xml             | 36 ++++++++++++++++++-
 bt5/erp5_base/bt/revision                     |  2 +-
 2 files changed, 36 insertions(+), 2 deletions(-)

diff --git a/bt5/erp5_base/WorkflowTemplateItem/portal_workflow/cached_convertible_interaction_workflow/interactions/Document_updateContentMd5.xml b/bt5/erp5_base/WorkflowTemplateItem/portal_workflow/cached_convertible_interaction_workflow/interactions/Document_updateContentMd5.xml
index 8c0c2a6c76..c39d687887 100644
--- a/bt5/erp5_base/WorkflowTemplateItem/portal_workflow/cached_convertible_interaction_workflow/interactions/Document_updateContentMd5.xml
+++ b/bt5/erp5_base/WorkflowTemplateItem/portal_workflow/cached_convertible_interaction_workflow/interactions/Document_updateContentMd5.xml
@@ -48,7 +48,7 @@
         <item>
             <key> <string>guard</string> </key>
             <value>
-              <none/>
+              <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
             </value>
         </item>
         <item>
@@ -91,4 +91,38 @@
       </dictionary>
     </pickle>
   </record>
+  <record id="2" aka="AAAAAAAAAAI=">
+    <pickle>
+      <tuple>
+        <global name="Guard" module="Products.DCWorkflow.Guard"/>
+        <tuple/>
+      </tuple>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>expr</string> </key>
+            <value>
+              <persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
+            </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+  <record id="3" aka="AAAAAAAAAAM=">
+    <pickle>
+      <tuple>
+        <global name="Expression" module="Products.CMFCore.Expression"/>
+        <tuple/>
+      </tuple>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>text</string> </key>
+            <value> <string>not:here/isTempObject</string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
 </ZopeData>
diff --git a/bt5/erp5_base/bt/revision b/bt5/erp5_base/bt/revision
index bb75777b93..b322bede21 100644
--- a/bt5/erp5_base/bt/revision
+++ b/bt5/erp5_base/bt/revision
@@ -1 +1 @@
-728
\ No newline at end of file
+729
\ No newline at end of file
-- 
2.30.9