From: Dan Brook Date: Wed, 11 Nov 2009 16:35:18 +0000 (+0000) Subject: Fixed bug in /summary where repos with < 10 branches display empty branches. X-Git-Tag: 0.000000_01~48 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=0969b4114dec66a310d70321d0b58643554c0a59;p=catagits%2FGitalist.git Fixed bug in /summary where repos with < 10 branches display empty branches. Reinstated project summary on /summary. Still needs tightening up though. --- diff --git a/lib/Gitalist/Controller/Root.pm b/lib/Gitalist/Controller/Root.pm index 289c9e6..de67ad3 100644 --- a/lib/Gitalist/Controller/Root.pm +++ b/lib/Gitalist/Controller/Root.pm @@ -123,7 +123,7 @@ sub summary : Local { count => $maxitems, )], refs => $project->references, - heads => [ @heads[0 .. $maxitems] ], + heads => [ @heads[0 .. ($#heads < $maxitems ? $#heads : $maxitems)] ], action => 'summary', ); } diff --git a/root/summary.tt2 b/root/summary.tt2 index a792220..fc9118d 100644 --- a/root/summary.tt2 +++ b/root/summary.tt2 @@ -1,7 +1,15 @@ [% PROCESS 'nav/actions.tt2' object = head %] +
+
+
description
[% info.description %]
+
owner
[% info.owner %]
+
last change
[% info.last_change %]
+
+
+

shortlog

[% INCLUDE '_shortlog.tt2' %] -

heads

+

branches

[% INCLUDE '_heads.tt2' %]