Commit 1a39a60e authored by Vincent Pelletier's avatar Vincent Pelletier

Preserve original file's indentation.

For easier copy/paste from original file.
parent ea27cd49
...@@ -14,7 +14,8 @@ ...@@ -14,7 +14,8 @@
from Products.ExternalMethod.ExternalMethod import ExternalMethod from Products.ExternalMethod.ExternalMethod import ExternalMethod
from App.Extensions import FuncCode, getObject from App.Extensions import FuncCode, getObject
def getFunction(self, reload=False, f=None): if 1:
def getFunction(self, reload=False, f=None):
""" """
Patch to get ZODB Component Extension function if available, otherwise Patch to get ZODB Component Extension function if available, otherwise
fallback on filesystem Extension fallback on filesystem Extension
...@@ -34,10 +35,10 @@ def getFunction(self, reload=False, f=None): ...@@ -34,10 +35,10 @@ def getFunction(self, reload=False, f=None):
self._v_f = f self._v_f = f
return f return f
ExternalMethod.getFunction = getFunction ExternalMethod.getFunction = getFunction
ExternalMethod__call__ = ExternalMethod.__call__ ExternalMethod__call__ = ExternalMethod.__call__
def __call__(self, *args, **kw): def __call__(self, *args, **kw):
""" """
Patch to call ZODB Component Extension, by trying first to import ZODB Patch to call ZODB Component Extension, by trying first to import ZODB
Component Extension if available, otherwise fallback on filesystem Component Extension if available, otherwise fallback on filesystem
...@@ -74,4 +75,4 @@ def __call__(self, *args, **kw): ...@@ -74,4 +75,4 @@ def __call__(self, *args, **kw):
finally: finally:
tb = None tb = None
ExternalMethod.__call__ = __call__ ExternalMethod.__call__ = __call__
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