aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Youri/Submit/Check/Type.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Youri/Submit/Check/Type.pm')
-rw-r--r--lib/Youri/Submit/Check/Type.pm13
1 files changed, 7 insertions, 6 deletions
diff --git a/lib/Youri/Submit/Check/Type.pm b/lib/Youri/Submit/Check/Type.pm
index e03fa80..4bdb793 100644
--- a/lib/Youri/Submit/Check/Type.pm
+++ b/lib/Youri/Submit/Check/Type.pm
@@ -1,9 +1,9 @@
# $Id: /local/youri/soft/trunk/lib/Youri/Upload/Check/Tag.pm 1642 2006-03-29T06:49:43.840267Z guillaume $
-package Youri::Upload::Check::Type;
+package Youri::Submit::Check::Type;
=head1 NAME
-Youri::Upload::Check::Type - Type check
+Youri::Submit::Check::Type - Type check
=head1 DESCRIPTION
@@ -14,7 +14,7 @@ This check plugin rejects packages with incorrect type.
use warnings;
use strict;
use Carp;
-use base qw/Youri::Upload::Check/;
+use base qw/Youri::Submit::Check/;
sub _init {
my $self = shift;
@@ -33,13 +33,14 @@ sub run {
my ($self, $package, $repository, $target, $define) = @_;
croak "Not a class method" unless ref $self;
+ my @errors;
+
my $type = $package->get_type();
if ($type ne $self->{_type}) {
- $self->{_error} = "invalid type $type";
- return 0;
+ push(@errors, "invalid type $type");
}
- return 1;
+ return @errors;
}
=head1 COPYRIGHT AND LICENSE