Added session object to kwarg of inlinefuncs. This means that the new call signature for inlinefuncs is funcname(text, *args, **kwargs), where **kwargs are only used for engine-related things (currently only session=session).

This commit is contained in:
Griatch 2014-10-26 10:46:22 +01:00
parent 5b42b31240
commit 6ef4467203
2 changed files with 19 additions and 9 deletions

View file

@ -237,7 +237,7 @@ class ServerSession(Session):
"""
text = text if text else ""
if INLINEFUNC_ENABLED and not "raw" in kwargs:
text = parse_inlinefunc(text, strip="strip_inlinefunc" in kwargs)
text = parse_inlinefunc(text, strip="strip_inlinefunc" in kwargs, session=self)
self.sessionhandler.data_out(self, text=text, **kwargs)
def __eq__(self, other):