Commit f1efa141 authored by Alexandre Boeglin's avatar Alexandre Boeglin

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
parent 9aa2e141
...@@ -111,7 +111,7 @@ class ActiveObject(ExtensionClass.Base): ...@@ -111,7 +111,7 @@ class ActiveObject(ExtensionClass.Base):
# a queue can be provided as well as extra parameters # a queue can be provided as well as extra parameters
# which can be used for example to define deferred tasks # which can be used for example to define deferred tasks
try: try:
return activity_tool.activate(self, activity, active_process, **kw) return activity_tool.activateObject(self, activity, active_process, **kw)
except ConflictError: except ConflictError:
raise raise
except: except:
......
...@@ -613,7 +613,8 @@ class ActivityTool (Folder, UniqueObject): ...@@ -613,7 +613,8 @@ class ActivityTool (Folder, UniqueObject):
return 1 return 1
return 0 return 0
def activate(self, object, activity, active_process, **kw): security.declarePrivate('activateObject')
def activateObject(self, object, activity, active_process, **kw):
global is_initialized global is_initialized
if not is_initialized: self.initialize() if not is_initialized: self.initialize()
if getattr(self, '_v_activity_buffer', None) is None: if getattr(self, '_v_activity_buffer', None) is None:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment