Patchwork [6,of,6] hgweb: remove unused argument 'tmpl' from listfilediffs()

login
register
mail settings
Submitter Yuya Nishihara
Date May 10, 2018, 2:16 p.m.
Message ID <743ff7bdbb3c9c7279ee.1525961771@mimosa>
Download mbox | patch
Permalink /patch/31463/
State Accepted
Headers show

Comments

Yuya Nishihara - May 10, 2018, 2:16 p.m.
# HG changeset patch
# User Yuya Nishihara <yuya@tcha.org>
# Date 1522766095 -32400
#      Tue Apr 03 23:34:55 2018 +0900
# Node ID 743ff7bdbb3c9c7279ee6eb379107757cff48b72
# Parent  9c179b856572b90bb7f6db3131ba1b1f607c2f68
hgweb: remove unused argument 'tmpl' from listfilediffs()
Augie Fackler - May 11, 2018, 4:44 a.m.
On Thu, May 10, 2018 at 11:16:11PM +0900, Yuya Nishihara wrote:
> # HG changeset patch
> # User Yuya Nishihara <yuya@tcha.org>
> # Date 1522766095 -32400
> #      Tue Apr 03 23:34:55 2018 +0900
> # Node ID 743ff7bdbb3c9c7279ee6eb379107757cff48b72
> # Parent  9c179b856572b90bb7f6db3131ba1b1f607c2f68
> hgweb: remove unused argument 'tmpl' from listfilediffs()

queued, thanks

Patch

diff --git a/mercurial/hgweb/webcommands.py b/mercurial/hgweb/webcommands.py
--- a/mercurial/hgweb/webcommands.py
+++ b/mercurial/hgweb/webcommands.py
@@ -296,8 +296,7 @@  def _search(web):
             count += 1
             n = ctx.node()
             showtags = webutil.showtag(web.repo, 'changelogtag', n)
-            files = webutil.listfilediffs(web.tmpl, ctx.files(), n,
-                                          web.maxfiles)
+            files = webutil.listfilediffs(ctx.files(), n, web.maxfiles)
 
             lm = webutil.commonentry(web.repo, ctx)
             lm.update({
diff --git a/mercurial/hgweb/webutil.py b/mercurial/hgweb/webutil.py
--- a/mercurial/hgweb/webutil.py
+++ b/mercurial/hgweb/webutil.py
@@ -445,7 +445,7 @@  def changelistentry(web, ctx):
     rev = ctx.rev()
     n = ctx.node()
     showtags = showtag(repo, 'changelogtag', n)
-    files = listfilediffs(web.tmpl, ctx.files(), n, web.maxfiles)
+    files = listfilediffs(ctx.files(), n, web.maxfiles)
 
     entry = commonentry(repo, ctx)
     entry.update(
@@ -515,7 +515,7 @@  def _listfilediffsgen(context, files, no
     if len(files) > max:
         yield context.process('fileellipses', {})
 
-def listfilediffs(tmpl, files, node, max):
+def listfilediffs(files, node, max):
     return templateutil.mappedgenerator(_listfilediffsgen,
                                         args=(files, node, max))