]> iEval git - gruntmaster-page.git/commitdiff
Merge branch 'master' into newmc
authorMarius Gavrilescu <marius@ieval.ro>
Tue, 24 Feb 2015 20:05:02 +0000 (22:05 +0200)
committerMarius Gavrilescu <marius@ieval.ro>
Tue, 24 Feb 2015 20:05:02 +0000 (22:05 +0200)
1  2 
lib/Plack/App/Gruntmaster.pm

index ef80f50eb8fa58c36d6f37691a15504ec7d380b1,a7e4e1dd52dc63c335482347c70359aedd42c400..80bcc1a9c130563aacdce3ac9b72aaade7d33d6b
@@@ -124,7 -124,7 +124,7 @@@ sub dispatch_request
                        my $private = job->private || job->problem->private || job->contest && job->contest->is_running;
                        forbid !$isowner && $private;
                        my $privacy = $private ? 'private' : 'public';
-                       my @headers = ('X-Forever' => 1, 'Cache-Control' => "$privacy, max-age=604800", 'Content-Type' => CONTENT_TYPES->{job->format});
+                       my @headers = ('X-Forever' => 1, 'Cache-Control' => "$privacy, max-age=604800", 'Content-Type' => CONTENT_TYPES->{job->extension});
                        push @headers, (Vary => 'Authorization') if $private;
                        [200, \@headers, [job->source]]
                },
  
                sub (/ed/:contest) {
                        forbid contest->is_running;
 -                      response ed => 'Editorial of ' . contest->name, db->problem_list(contest => $_{contest}, solution => 1);
 +                      my $pblist = db->problem_list(contest => $_{contest}, solution => 1);
 +                      response ed => 'Editorial of ' . contest->name, {%$pblist, editorial => contest->editorial};
                },
  
                sub (/login) {
This page took 0.028635 seconds and 4 git commands to generate.