[PATCH 3 of 4] hgweb: remove useless notip handling from bookmarks listing
Yuya Nishihara
yuya at tcha.org
Sat Apr 9 20:04:15 CDT 2011
# HG changeset patch
# User Yuya Nishihara <yuya at tcha.org>
# Date 1302397299 -32400
# Node ID 1ba9f2eb488b892a4939a0d3eea48f0a51bb3e86
# Parent 6e0fb0c181d9cb81471dcb580f7d88209aae50ba
hgweb: remove useless notip handling from bookmarks listing
diff --git a/mercurial/hgweb/webcommands.py b/mercurial/hgweb/webcommands.py
--- a/mercurial/hgweb/webcommands.py
+++ b/mercurial/hgweb/webcommands.py
@@ -395,11 +395,9 @@ def bookmarks(web, req, tmpl):
i = web.repo._bookmarks.items()
parity = paritygen(web.stripecount)
- def entries(notip=False, limit=0, **map):
+ def entries(limit=0, **map):
count = 0
for k, n in sorted(i):
- if notip and k == "tip":
- continue
if limit > 0 and count >= limit:
continue
count = count + 1
@@ -410,9 +408,8 @@ def bookmarks(web, req, tmpl):
return tmpl("bookmarks",
node=hex(web.repo.changelog.tip()),
- entries=lambda **x: entries(False, 0, **x),
- entriesnotip=lambda **x: entries(True, 0, **x),
- latestentry=lambda **x: entries(True, 1, **x))
+ entries=lambda **x: entries(0, **x),
+ latestentry=lambda **x: entries(1, **x))
def branches(web, req, tmpl):
tips = (web.repo[n] for t, n in web.repo.branchtags().iteritems())
More information about the Mercurial-devel
mailing list