From f1efa141f84715ea2830f1c0449ab6bff9802d0f Mon Sep 17 00:00:00 2001
From: Alexandre Boeglin <alex@nexedi.com>
Date: Tue, 13 Feb 2007 14:57:44 +0000
Subject: [PATCH] Renamed ActivityTool.activate to activateObject to prevent
 conflict with ActiveObject.activate. Also added a security declaration to
 prevent the mehtod from being called by a python script.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@12664 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/CMFActivity/ActiveObject.py | 2 +-
 product/CMFActivity/ActivityTool.py | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/product/CMFActivity/ActiveObject.py b/product/CMFActivity/ActiveObject.py
index e3d7c67100..128d822dd8 100644
--- a/product/CMFActivity/ActiveObject.py
+++ b/product/CMFActivity/ActiveObject.py
@@ -111,7 +111,7 @@ class ActiveObject(ExtensionClass.Base):
     # a queue can be provided as well as extra parameters
     # which can be used for example to define deferred tasks
     try:
-      return activity_tool.activate(self, activity, active_process, **kw)
+      return activity_tool.activateObject(self, activity, active_process, **kw)
     except ConflictError:
       raise
     except:
diff --git a/product/CMFActivity/ActivityTool.py b/product/CMFActivity/ActivityTool.py
index 33de7aae2d..1625ea241c 100644
--- a/product/CMFActivity/ActivityTool.py
+++ b/product/CMFActivity/ActivityTool.py
@@ -613,7 +613,8 @@ class ActivityTool (Folder, UniqueObject):
           return 1
       return 0
 
-    def activate(self, object, activity, active_process, **kw):
+    security.declarePrivate('activateObject')
+    def activateObject(self, object, activity, active_process, **kw):
       global is_initialized
       if not is_initialized: self.initialize()
       if getattr(self, '_v_activity_buffer', None) is None:
-- 
2.30.9