Remove AgeRange table and first pass of fixing tests

This commit is contained in:
Tom Bloor 2017-06-13 21:02:24 +01:00
parent a1a608ea44
commit d73ddb6ba2
6 changed files with 55 additions and 95 deletions

View file

@ -48,6 +48,11 @@ sub register {
return $value > $check ? undef : 1;
});
$app->validator->add_check( lt_num => sub {
my ( $validation, $name, $value, $check ) = @_;
return $value < $check ? undef : 1;
});
$app->validator->add_check( filetype => sub {
my ( $validation, $name, $value, $filetype ) = @_;
my ( undef, undef, $extension ) = fileparse $value->filename, qr/\.[^.]*/;