From f20668d742eae08b6e1d24048572bdeef0eb51d3 Mon Sep 17 00:00:00 2001 From: Marius Gavrilescu Date: Tue, 3 Mar 2015 18:39:11 +0200 Subject: [PATCH] Remove no longer useful is_private and is_in_archive methods --- lib/Gruntmaster/Data/Result/Problem.pm | 20 -------------------- t/Gruntmaster-Data.t | 20 +------------------- 2 files changed, 1 insertion(+), 39 deletions(-) diff --git a/lib/Gruntmaster/Data/Result/Problem.pm b/lib/Gruntmaster/Data/Result/Problem.pm index 2ce4f68..cec4cc8 100644 --- a/lib/Gruntmaster/Data/Result/Problem.pm +++ b/lib/Gruntmaster/Data/Result/Problem.pm @@ -332,18 +332,6 @@ after qw/insert update delete/ => sub { Gruntmaster::Data::purge '/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; -} - -sub is_in_archive { - my ($self, $time) = @_; - 0 == grep { $_->contest->is_running($time) } $self->contest_problems; -} - sub rerun { $_->rerun for shift->jobs } @@ -354,14 +342,6 @@ __END__ =head1 METHODS -=head2 is_private(I<[$time]>) - -Returns true if the problem is private at time I<$time> (which defaults to C