From 55ff35cb649e77f7633f9a30e9988ecad1371fe5 Mon Sep 17 00:00:00 2001 From: Petr Baudis Date: Fri, 6 Oct 2006 15:57:52 +0200 Subject: [PATCH] Show snapshot link in shortlog only if have_snapsho Signed-off-by: Petr Baudis Signed-off-by: Junio C Hamano --- gitweb/gitweb.perl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index 3cc0e965fc..276a84244b 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -2033,8 +2033,10 @@ sub git_shortlog_body { print "\n" . "" . $cgi->a({-href => href(action=>"commitdiff", hash=>$commit)}, "commitdiff") . " | " . - $cgi->a({-href => href(action=>"tree", hash=>$commit, hash_base=>$commit)}, "tree") . " | " . - $cgi->a({-href => href(action=>"snapshot", hash=>$commit)}, "snapshot"); + $cgi->a({-href => href(action=>"tree", hash=>$commit, hash_base=>$commit)}, "tree"); + if (gitweb_have_snapshot()) { + print " | " . $cgi->a({-href => href(action=>"snapshot", hash=>$commit)}, "snapshot"); + } print "\n" . "\n"; } -- 2.11.4.GIT