Mercurial > hg
changeset 6168:2ab54f48dbe8
hgweb: fix parameter mixup (issue1001)
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Sat, 23 Feb 2008 11:19:59 +0100 |
parents | f53b9a383476 |
children | 55455556f921 |
files | mercurial/hgweb/hgweb_mod.py tests/test-hgweb-commands tests/test-hgweb-commands.out |
diffstat | 3 files changed, 7 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/hgweb/hgweb_mod.py Sat Feb 23 11:18:34 2008 +0100 +++ b/mercurial/hgweb/hgweb_mod.py Sat Feb 23 11:19:59 2008 +0100 @@ -444,12 +444,13 @@ for i in xrange(start, end): ctx = self.repo.changectx(i) n = ctx.node() + showtags = self.showtag(tmpl, 'changelogtag', n) l.insert(0, {"parity": parity.next(), "author": ctx.user(), "parent": self.siblings(ctx.parents(), i - 1), "child": self.siblings(ctx.children(), i + 1), - "changelogtag": self.showtag("changelogtag",n), + "changelogtag": showtags, "desc": ctx.description(), "date": ctx.date(), "files": self.listfilediffs(tmpl, ctx.files(), n), @@ -513,13 +514,14 @@ count += 1 n = ctx.node() + showtags = self.showtag(tmpl, 'changelogtag', n) yield tmpl('searchentry', parity=parity.next(), author=ctx.user(), parent=self.siblings(ctx.parents()), child=self.siblings(ctx.children()), - changelogtag=self.showtag("changelogtag",n), + changelogtag=showtags, desc=ctx.description(), date=ctx.date(), files=self.listfilediffs(tmpl, ctx.files(), n), @@ -542,6 +544,7 @@ def changeset(self, tmpl, ctx): n = ctx.node() + showtags = self.showtag(tmpl, 'changesettag', n) parents = ctx.parents() p1 = parents[0].node() @@ -561,7 +564,7 @@ node=hex(n), parent=self.siblings(parents), child=self.siblings(ctx.children()), - changesettag=self.showtag("changesettag",n), + changesettag=showtags, author=ctx.user(), desc=ctx.description(), date=ctx.date(),
--- a/tests/test-hgweb-commands Sat Feb 23 11:18:34 2008 +0100 +++ b/tests/test-hgweb-commands Sat Feb 23 11:19:59 2008 +0100 @@ -21,6 +21,7 @@ "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/1/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/1/foo/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/shortlog/' | sed "s/[0-9]* years/many years/" +"$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/rev/0/' | sed "s/[0-9]* years ago/long ago/g" "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/rev/1/?style=raw' echo % File-related