From: Marius Gavrilescu Date: Fri, 28 Mar 2014 20:25:58 +0000 (+0200) Subject: Use opens correctly when computing standings X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=9484fd0b6fc494111e72a65133b4850bc6e852e2;hp=e8cc4fa43dad618ac488e70e9448831bfb5bc7da;p=gruntmaster-page.git Use opens correctly when computing standings --- diff --git a/lib/Gruntmaster/Page/St.pm b/lib/Gruntmaster/Page/St.pm index f5c4049..4625138 100644 --- a/lib/Gruntmaster/Page/St.pm +++ b/lib/Gruntmaster/Page/St.pm @@ -31,7 +31,7 @@ sub _generate{ for my $job (db($env)->jobs->search({contest => $ct && $ct->id}, {order_by => 'id'})) { if ($ct) { - my $open = db($env)->open($ct->id, $job->problem->id, $job->owner->id); + my $open = db($env)->opens->find($ct->id, $job->problem->id, $job->owner->id); my $time = $job->date - ($open || $ct->start); next if $time < 0; my $value = $job->problem->value // LEVEL_VALUES->{$job->problem->level};