]> iEval git - plack-app-gruntmaster.git/commitdiff
Make jobs private during contests, not just before contests
authorMarius Gavrilescu <marius@ieval.ro>
Wed, 26 Mar 2014 17:05:12 +0000 (19:05 +0200)
committerMarius Gavrilescu <marius@ieval.ro>
Wed, 26 Mar 2014 17:05:12 +0000 (19:05 +0200)
app.psgi

index de07be799a9cac8c3e6cc5014ef95ef2b5ce49cc..b6ba34f63580e2586cb3f6cab6431383f4e0160b 100644 (file)
--- a/app.psgi
+++ b/app.psgi
@@ -48,7 +48,7 @@ sub admin_required {
        my $env = $_[1];
        return $db->contest($env->{'gruntmaster.contest'})->owner->id if $env->{'gruntmaster.contest'} && $db->contest($env->{'gruntmaster.contest'})->start > time;
        return $db->problem($1)->owner->id if m,^/pb/$word, && is_problem_private $1 || $env->{'gruntmaster.problem'} && is_problem_private $env->{'gruntmaster.problem'};
-       return $db->job    ($1)->owner->id if m,^/log/(?:src/)?$number, && ($db->job($1)->private || is_problem_private $db->job($1)->problem->id || $db->job($1)->contest && $db->contest($db->job($1)->contest)->start > time);
+       return $db->job    ($1)->owner->id if m,^/log/(?:src/)?$number, && ($db->job($1)->private || is_problem_private $db->job($1)->problem->id || $db->job($1)->contest && $db->contest($db->job($1)->contest)->stop > time);
        ''
 }
 
This page took 0.025865 seconds and 4 git commands to generate.