[Catalyst-commits] r7404 - in trunk/Catalyst-Authentication-Store-DBIx-Class: . lib/Catalyst/Authentication/Store/DBIx lib/Catalyst/Authentication/Store/DBIx/Class

bricas at dev.catalyst.perl.org bricas at dev.catalyst.perl.org
Wed Jan 23 19:02:18 GMT 2008


Author: bricas
Date: 2008-01-23 19:02:18 +0000 (Wed, 23 Jan 2008)
New Revision: 7404

Modified:
   trunk/Catalyst-Authentication-Store-DBIx-Class/Changes
   trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class.pm
   trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class/User.pm
Log:
explicitly call auto_create and auto_update properly. jayk -- fix them docs. :)

Modified: trunk/Catalyst-Authentication-Store-DBIx-Class/Changes
===================================================================
--- trunk/Catalyst-Authentication-Store-DBIx-Class/Changes	2008-01-20 15:16:46 UTC (rev 7403)
+++ trunk/Catalyst-Authentication-Store-DBIx-Class/Changes	2008-01-23 19:02:18 UTC (rev 7404)
@@ -1,5 +1,11 @@
 Revision history for Catalyst-Plugin-Authentication-Store-DBIx-Class
 
+0.102   2008-01-23
+        Catalyst::Authentication::Store::DBIx::Class::User
+          - Explicitly call auto_create() against resultset()
+          - Explicitly call auto_update() against _user()
+          - Document the above
+
 0.101   2007-12-02
         Implemented basic auto_update_user and auto_create_user support
 

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-20 15:16:46 UTC (rev 7403)
+++ trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class/User.pm	2008-01-23 19:02:18 UTC (rev 7404)
@@ -168,6 +168,17 @@
     return $self->get_object;
 }
 
+sub auto_create {
+    my $self = shift;
+    $self->_user( $self->resultset->auto_create( @_ ) );
+    return $self;
+}
+
+sub auto_update {
+    my $self = shift;
+    $self->_user->auto_update( @_ );
+}
+
 sub AUTOLOAD {
     my $self = shift;
     (my $method) = (our $AUTOLOAD =~ /([^:]+)$/);
@@ -244,6 +255,16 @@
 
 Synonym for get_object
 
+=head2 auto_create
+
+This will delegate a call to 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.
+
 =head1 BUGS AND LIMITATIONS
 
 None known currently, please email the author if you find any.

Modified: trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class.pm
===================================================================
--- trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class.pm	2008-01-20 15:16:46 UTC (rev 7403)
+++ trunk/Catalyst-Authentication-Store-DBIx-Class/lib/Catalyst/Authentication/Store/DBIx/Class.pm	2008-01-23 19:02:18 UTC (rev 7404)
@@ -4,7 +4,7 @@
 use warnings;
 use base qw/Class::Accessor::Fast/;
 
-our $VERSION= "0.101";
+our $VERSION= "0.102";
 
 
 BEGIN {




More information about the Catalyst-commits mailing list