Commit 7e911d75 authored by Sebastien Robin's avatar Sebastien Robin

if the method is a string, then we must retrieve the real method

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@2709 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent aca23aab
......@@ -174,7 +174,10 @@ class Selection(Acquisition.Implicit, Traversable, Persistent):
#LOG("Selection", 0, str(method))
#LOG('Selection', 0, "self.invert_mode = %s" % repr(self.invert_mode))
if self.invert_mode is 0:
if method is None:
if method is None or type(method) is type('a'):
method_path = method or self.method_path
method = context.unrestrictedTraverse(method_path)
if type(method) is type('a'):
method = context.unrestrictedTraverse(self.method_path)
sort_on = getattr(self, 'sort_on', [])
if len(sort_on) == 0:
......
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