[PATCH] hgweb: remove an extra call to nodebranchnodefault() in changesetentry()

Anton Shestakov engored at ya.ru
Tue May 26 14:58:59 UTC 2015


# HG changeset patch
# User Anton Shestakov <engored at ya.ru>
# Date 1432652310 -28800
#      Tue May 26 22:58:30 2015 +0800
# Node ID 2b7406cc18592445a8d37b4ff53549bedaba3c94
# Parent  605b1d32c1c011d56233f28923ee5354fce7e426
hgweb: remove an extra call to nodebranchnodefault() in changesetentry()

showbranch variable already contains the result of nodebranchnodefault(ctx), so
it can be reused.

diff --git a/mercurial/hgweb/webutil.py b/mercurial/hgweb/webutil.py
--- a/mercurial/hgweb/webutil.py
+++ b/mercurial/hgweb/webutil.py
@@ -331,7 +331,7 @@ def changesetentry(web, req, tmpl, ctx):
         archives=web.archivelist(ctx.hex()),
         tags=nodetagsdict(web.repo, ctx.node()),
         bookmarks=nodebookmarksdict(web.repo, ctx.node()),
-        branch=nodebranchnodefault(ctx),
+        branch=showbranch,
         inbranch=nodeinbranch(web.repo, ctx),
         branches=nodebranchdict(web.repo, ctx))
 


More information about the Mercurial-devel mailing list