From e890b3aeae1a49b16a4a1aac58cd794ae9c6f050 Mon Sep 17 00:00:00 2001 From: Marius Gavrilescu Date: Sun, 25 Jan 2015 23:23:02 +0200 Subject: [PATCH] Do not include statement in problem_list --- lib/Gruntmaster/Data.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Gruntmaster/Data.pm b/lib/Gruntmaster/Data.pm index 4cb6512..6cdf3f5 100644 --- a/lib/Gruntmaster/Data.pm +++ b/lib/Gruntmaster/Data.pm @@ -25,7 +25,7 @@ use HTTP::Tiny; use PerlX::Maybe qw/maybe/; use Sub::Name qw/subname/; -use constant PROBLEM_PUBLIC_COLUMNS => [qw/id author writer level name owner private statement timeout olimit value/]; +use constant PROBLEM_PUBLIC_COLUMNS => [qw/id author writer level name owner private timeout olimit value/]; use constant USER_PUBLIC_COLUMNS => [qw/id admin name town university level/]; use constant JOBS_PER_PAGE => 10; @@ -91,6 +91,7 @@ sub problem_entry { my ($self, $id, $contest, $user) = @_; my $running = $contest && $self->contest($contest)->is_running; my $columns = PROBLEM_PUBLIC_COLUMNS; + push @$columns, 'statement'; push @$columns, 'solution' unless $running; my $pb = $self->problems->find($id, {columns => $columns, prefetch => 'owner'}); my $open; -- 2.39.2