summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0ff5ec7)
raw | patch | inline | side by side (parent: 0ff5ec7)
author | Robert Fitzsimons <robfitz@273k.net> | |
Fri, 22 Dec 2006 19:38:14 +0000 (19:38 +0000) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sat, 23 Dec 2006 07:18:16 +0000 (23:18 -0800) |
Don't call gitweb_have_snapshot from within the loop.
Signed-off-by: Robert Fitzsimons <robfitz@273k.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Signed-off-by: Robert Fitzsimons <robfitz@273k.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
gitweb/gitweb.perl | patch | blob | history |
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 01e3a8adaa0977207965fee9d723bc4a1c817ada..d2ddac8bf3bae0c2ead4583a3368db2d6bd9fe81 100755 (executable)
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
# uses global variable $project
my ($revlist, $from, $to, $refs, $extra) = @_;
+ my $have_snapshot = gitweb_have_snapshot();
+
$from = 0 unless defined $from;
$to = $#{$revlist} if (!defined $to || $#{$revlist} < $to);
$cgi->a({-href => href(action=>"commit", hash=>$commit)}, "commit") . " | " .
$cgi->a({-href => href(action=>"commitdiff", hash=>$commit)}, "commitdiff") . " | " .
$cgi->a({-href => href(action=>"tree", hash=>$commit, hash_base=>$commit)}, "tree");
- if (gitweb_have_snapshot()) {
+ if ($have_snapshot) {
print " | " . $cgi->a({-href => href(action=>"snapshot", hash=>$commit)}, "snapshot");
}
print "</td>\n" .