[Catalyst-commits] r9591 -
trunk/Catalyst-Plugin-Authentication/lib/Catalyst/Authentication/Realm
jayk at dev.catalyst.perl.org
jayk at dev.catalyst.perl.org
Sat Mar 28 01:57:36 GMT 2009
Author: jayk
Date: 2009-03-28 01:57:36 +0000 (Sat, 28 Mar 2009)
New Revision: 9591
Modified:
trunk/Catalyst-Plugin-Authentication/lib/Catalyst/Authentication/Realm/Progressive.pm
Log:
Fixing Progressive to have it's own new(), since it doesn't use a
store or credential directly but instead defers to other realms
Modified: trunk/Catalyst-Plugin-Authentication/lib/Catalyst/Authentication/Realm/Progressive.pm
===================================================================
--- trunk/Catalyst-Plugin-Authentication/lib/Catalyst/Authentication/Realm/Progressive.pm 2009-03-28 01:52:44 UTC (rev 9590)
+++ trunk/Catalyst-Plugin-Authentication/lib/Catalyst/Authentication/Realm/Progressive.pm 2009-03-28 01:57:36 UTC (rev 9591)
@@ -139,6 +139,21 @@
return;
}
+## we can not rely on inheriting new() because in this case we do not
+## load a credential or store, which is what new() sets up in the
+## standard realm. So we have to create our realm object, set our name
+## and return $self in order to avoid nasty warnings.
+
+sub new {
+ my ($class, $realmname, $config, $app) = @_;
+
+ my $self = { config => $config };
+ bless $self, $class;
+
+ $self->name($realmname);
+ return $self;
+}
+
=head1 AUTHORS
J. Shirley C<< <jshirley at cpan.org> >>
More information about the Catalyst-commits
mailing list