Commit 7cdf2dec authored by wenjie.zheng's avatar wenjie.zheng

Fix new line markers.

parents 0c9063ec 48a1ae7b
......@@ -3633,5 +3633,3 @@ class TempBase(Base):
# allow_class(TempBase) in ERP5Type/Document/__init__.py will trample our
# ClassSecurityInfo with one that doesn't declare our public methods
InitializeClass(TempBase)
# -*- coding: utf-8 -*-
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (c) 2001 Zope Corporation and Contributors. All Rights Reserved.
......@@ -290,8 +289,8 @@ class PortalTypeMetaClass(GhostBaseMetaClass, PropertyHolder):
portal_type = site.getDefaultModule(portal_type="portal_types")
pt = portal_type._getOb(cls.__name__, None)
if pt is not None:
wf = getattr(pt, 'workflow_list', None)
if wf is not None:
workflow_list = getattr(pt, 'workflow_list', None)
if workflow_list is not None:
portal_ERP5Workflow = site.getDefaultModule(portal_type="Workflow")
if portal_ERP5Workflow is None:
LOG("ERP5Type.Dynamic", WARNING,
......
......@@ -151,6 +151,7 @@ class Workflow(XMLObject):
def _getERP5WorkflowStateOf(self, ob):
bc_id = self.getStateBaseCategory()
state_path = ob.getCategoryList()
### should avoid using lstrip
state_path = state_path[0].lstrip("%s/"%bc_id)
if state_path is not 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