hgext/keyword.py
changeset 6393 894875eae49b
parent 6211 f89fd07fc51d
child 6416 c0476a6df325
--- a/hgext/keyword.py	Fri Mar 28 19:37:28 2008 +0100
+++ b/hgext/keyword.py	Fri Mar 28 19:40:44 2008 +0100
@@ -128,15 +128,21 @@
     _patch_diff(repo, node1=node1, node2=node2, files=files, match=match,
                 fp=fp, changes=changes, opts=opts)
 
+# monkeypatching hgweb functions changeset and filediff
+# actual monkeypatching is done at the bottom of reposetup()
+
+web_changeset = webcommands.changeset
+web_filediff = webcommands.filediff
+
 def _kwweb_changeset(web, req, tmpl):
     '''Wraps webcommands.changeset turning off keyword expansion.'''
     kwtools['templater'].matcher = util.never
-    return web.changeset(tmpl, web.changectx(req))
+    return web_changeset(web, req, tmpl)
 
 def _kwweb_filediff(web, req, tmpl):
     '''Wraps webcommands.filediff turning off keyword expansion.'''
     kwtools['templater'].matcher = util.never
-    return web.filediff(tmpl, web.filectx(req))
+    return web_filediff(web, req, tmpl)
 
 def _kwdispatch_parse(ui, args):
     '''Monkeypatch dispatch._parse to obtain running hg command.'''