summaryrefslogtreecommitdiff
path: root/usr/src/libpiny/lib/Piny/Repo.pm
diff options
context:
space:
mode:
authorJulian Blake Kongslie <jblake@omgwallhack.org>2010-07-07 16:00:00 -0700
committerJulian Blake Kongslie <jblake@omgwallhack.org>2010-07-07 16:00:00 -0700
commit26297ed05c122a0867a94f96a87b3bf58d1c52ee (patch)
tree79e3a035ce966de2846d2d1ef3eb8427cd2761b3 /usr/src/libpiny/lib/Piny/Repo.pm
parentd809044c2f00d7f8358dc8013c4e6639760aba67 (diff)
downloadpiny-code-26297ed05c122a0867a94f96a87b3bf58d1c52ee.tar.gz
piny-code-26297ed05c122a0867a94f96a87b3bf58d1c52ee.zip
Fix some type constraint stuff.
Diffstat (limited to 'usr/src/libpiny/lib/Piny/Repo.pm')
-rw-r--r--usr/src/libpiny/lib/Piny/Repo.pm8
1 files changed, 3 insertions, 5 deletions
diff --git a/usr/src/libpiny/lib/Piny/Repo.pm b/usr/src/libpiny/lib/Piny/Repo.pm
index 48690c4..926f199 100644
--- a/usr/src/libpiny/lib/Piny/Repo.pm
+++ b/usr/src/libpiny/lib/Piny/Repo.pm
@@ -4,7 +4,7 @@
package Piny::Repo;
use Moose;
-use Moose::Util::TypeConstraints;
+use Moose::Util::TypeConstraints qw( find_type_constraint );
use File::Find qw( find );
use File::Temp qw( );
@@ -31,8 +31,6 @@ subtype 'SimpleText'
=> message { 'That description is not in the correct format for a piny repo.' }
;
-Moose::Util::TypeConstraints::export_type_constraints_as_functions;
-
# Attributes
has 'name' =>
@@ -250,8 +248,8 @@ sub create {
my $user = Piny::Environment->new->user;
- Reponame->assert_valid( $name );
- SimpleText->assert_valid( $description );
+ find_type_constraint( "Reponame" )->assert_valid( $name );
+ find_type_constraint( "SimpleText" )->assert_valid( $description );
my $repo = $class->new( "name" => $name );