[Catalyst] login() error ?

Christopher H. Laco claco at chrislaco.com
Fri Dec 30 18:04:47 CET 2005


raptor wrote:
> I have :
> 
> use Catalyst qw/-Debug Prototype
>      Authentication Authentication::Store::Minimal Authentication::Credential::Password
>      Session Session::Store::FastMmap Session::State::Cookie /;
> 
> ......
> 
> sub login : Local {
>      my ($self, $c) = @_;
>      $c->login('blah',1);
>      $c->stash(template => 'login.tt2');
> }
> 
> And get this error :
> 
> Caught exception "Can't locate object method "login" via package "blah" (perhaps you forgot to load "blah"?)
> 
> Why is that ?

Don't put a method login() in MyApp.pm, or it goes boom.
Put login : Global somewhere other than MyApp.pm...


-=Chris
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: OpenPGP digital signature
Url : http://lists.rawmode.org/pipermail/catalyst/attachments/20051230/fb3b1824/signature.pgp


More information about the Catalyst mailing list