projects
/
gruntmaster-data.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4adba83
)
Make problems in running or finished contests public
author
Marius Gavrilescu
<marius@ieval.ro>
Fri, 6 Feb 2015 14:39:40 +0000
(16:39 +0200)
committer
Marius Gavrilescu
<marius@ieval.ro>
Fri, 6 Feb 2015 14:39:49 +0000
(16:39 +0200)
lib/Gruntmaster/Data/Result/Problem.pm
patch
|
blob
|
blame
|
history
diff --git
a/lib/Gruntmaster/Data/Result/Problem.pm
b/lib/Gruntmaster/Data/Result/Problem.pm
index 6b9b3bfff02ae3156c9332d5aa4cd0c35ed00641..8e073be710c67423e78cefbe2d7f53acc2aaa5ef 100644
(file)
--- a/
lib/Gruntmaster/Data/Result/Problem.pm
+++ b/
lib/Gruntmaster/Data/Result/Problem.pm
@@
-320,11
+320,12
@@
after qw/insert update delete/ => sub {
my ($self) = @_;
Gruntmaster::Data::purge '/pb/';
Gruntmaster::Data::purge '/pb/' . $self->id;
- Gruntmaster::Data::purge '/sol/' . $self->id;
+ Gruntmaster::Data::purge '/
c
sol/' . $self->id;
};
sub is_private {
my ($self, $time) = @_;
+ return 0 if grep { !$_->contest->is_pending($time) } $self->contest_problems;
return 1 if $self->private;
grep { $_->contest->is_pending($time) } $self->contest_problems;
}
This page took
0.010579 seconds
and
4
git commands to generate.