[Catalyst-commits] r7405 -
trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class
jayk at dev.catalyst.perl.org
jayk at dev.catalyst.perl.org
Wed Jan 23 19:21:04 GMT 2008
Author: jayk
Date: 2008-01-23 19:21:02 +0000 (Wed, 23 Jan 2008)
New Revision: 7405
Modified:
trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class/User.pm
Log:
Fixing docs for auto_update and auto_create to be more clear about their
behavior and possible gotchas
Modified: trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class/User.pm
===================================================================
--- trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class/User.pm 2008-01-23 19:02:18 UTC (rev 7404)
+++ trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class/User.pm 2008-01-23 19:21:02 UTC (rev 7405)
@@ -257,14 +257,26 @@
=head2 auto_create
-This will delegate a call to the C<auto_create()> method of the resultset associated
+This is called when the auto_create_user option is turned on in
+Catalyst::Plugin::Authenticate and a user matching the authinfo provided is not found.
+By default, this will call the C<auto_create()> method of the resultset associated
with this object. It is up to you to implement that method.
=head2 auto_update
-This will delegate a call to the C<auto_create()> method of the current instance of the resultset
-associated with this object. It is up to you to implement that method.
+This is called when the auto_update_user option is turned on in
+Catalyst::Plugin::Authenticate. Note that by default the DBIx::Class store
+uses every field in the authinfo hash to match the user. This means any
+information that is provided that does not match the user record will cause
+the user record to not be found. In order for the auto_update routine to be
+useful, you have to add the fields you wish to update to the
+'ignore_fields_in_find' authinfo element, or you must be using one of the advanced row
+retrieval methods (searchargs or resultset).
+By default, auto_update will call the C<auto_update()> method of the
+DBIx::Class::Row object associated with the user. It is up to you to implement
+that method (probably in your schema file)
+
=head1 BUGS AND LIMITATIONS
None known currently, please email the author if you find any.
More information about the Catalyst-commits
mailing list