From: matthewt Date: Sat, 15 Sep 2007 23:08:43 +0000 (+0000) Subject: profile class assertion X-Git-Tag: v1.003015~157 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2FDevel-REPL.git;a=commitdiff_plain;h=3bcf4eb89e6fd4f7ae37fae50255a2b09e655677;hp=e65ad1eb54618fdbbe9b17754f465ef1bf248cb2 profile class assertion git-svn-id: http://dev.catalyst.perl.org/repos/bast/trunk/Devel-REPL@3748 bd8105ee-0ff8-0310-8827-fb3f25b6796d --- diff --git a/lib/Devel/REPL/Script.pm b/lib/Devel/REPL/Script.pm index 277fc91..bf36136 100644 --- a/lib/Devel/REPL/Script.pm +++ b/lib/Devel/REPL/Script.pm @@ -32,6 +32,8 @@ sub load_profile { my ($self, $profile) = @_; $profile = "Devel::REPL::Profile::${profile}" unless $profile =~ /::/; Class::MOP::load_class($profile); + confess "Profile class ${profile} doesn't do 'Devel::REPL::Profile'" + unless $profile->does('Devel::REPL::Profile'); $profile->new->apply_profile($self->_repl); }