changeset 14514:175e4b9d8a96

web: prevent TypeError thrown when using the diffstat templates Remove the lambda used to wrap webutil.diffstat because: - functions passed to the templater must accept keyword arguments - webutil.diffstat is a generator, so already calculates the diffstat lazily This reverts the changes made to 1d3e2349304a after it was submitted to the mailing list but before it was queued.
author Steven Brown <StevenGBrown@gmail.com>
date Thu, 02 Jun 2011 18:52:31 +0800
parents 85fe676c27e9
children 76f295eaed86
files mercurial/hgweb/webcommands.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/hgweb/webcommands.py	Thu Jun 02 11:27:40 2011 -0500
+++ b/mercurial/hgweb/webcommands.py	Thu Jun 02 18:52:31 2011 +0800
@@ -271,7 +271,7 @@
     diffs = webutil.diffs(web.repo, tmpl, ctx, None, parity, style)
 
     parity = paritygen(web.stripecount)
-    diffstat = lambda: webutil.diffstat(tmpl, ctx, parity)
+    diffstat = webutil.diffstat(tmpl, ctx, parity)
 
     return tmpl('changeset',
                 diff=diffs,