From bfd8c0c41788b13ea012c5a423605e48f8ee706b Mon Sep 17 00:00:00 2001 From: Marius Gavrilescu Date: Fri, 14 Feb 2014 00:28:22 +0200 Subject: [PATCH] Sort contests by start date --- lib/Gruntmaster/Page/Ct.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Gruntmaster/Page/Ct.pm b/lib/Gruntmaster/Page/Ct.pm index b62b975..a21bf77 100644 --- a/lib/Gruntmaster/Page/Ct.pm +++ b/lib/Gruntmaster/Page/Ct.pm @@ -12,7 +12,7 @@ sub _generate{ debug $env => "language is '$lang'"; my (@running, @pending, @finished); - for (contests) { + for (sort {contest_start $a <=> contest_start $b}contests) { my $ct = { id => $_, name => contest_name, start => strftime ('%c', localtime contest_start), -- 2.39.2