Commit dd3478ee authored by Ken Manheimer's avatar Ken Manheimer

ExternalMethod.__call__(): When we've sniffed a 'self' arg, provide

self.aq_parent.this(), instead of just self.aq_parent, so we're sure
to get beyond doggone W wrapper objects.
parent 338176bb
......@@ -88,7 +88,7 @@
This product provides support for external methods, which allow
domain-specific customization of web environments.
"""
__version__='$Revision: 1.28 $'[11:-2]
__version__='$Revision: 1.29 $'[11:-2]
from Acquisition import Explicit
from Globals import Persistent, HTMLFile, MessageDialog, HTML
import OFS.SimpleItem
......@@ -251,7 +251,7 @@ class ExternalMethod(OFS.SimpleItem.Item, Persistent, Explicit,
if ((self.func_code.co_argcount-
len(self.func_defaults or ()) - 1 == len(args))
and self.func_code.co_varnames[0]=='self'):
return apply(f,(self.aq_parent,)+args,kw)
return apply(f,(self.aq_parent.this(),)+args,kw)
raise TypeError, v, tb
finally: tb=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