[Jifty-commit] r5152 - in jifty/trunk: lib/Jifty/Plugin/OAuth lib/Jifty/Plugin/OAuth/Model

Jifty commits jifty-commit at lists.jifty.org
Wed Feb 20 19:30:30 EST 2008


Author: sartak
Date: Wed Feb 20 19:30:29 2008
New Revision: 5152

Modified:
   jifty/trunk/   (props changed)
   jifty/trunk/lib/Jifty/Plugin/OAuth/Dispatcher.pm
   jifty/trunk/lib/Jifty/Plugin/OAuth/Model/Consumer.pm

Log:
 r51969 at onn:  sartak | 2008-02-20 19:30:15 -0500
 Instead of sticking 1 into is_oauthed, stick in the access token
 Fix a bug in updating a consumer's timestamp


Modified: jifty/trunk/lib/Jifty/Plugin/OAuth/Dispatcher.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Plugin/OAuth/Dispatcher.pm	(original)
+++ jifty/trunk/lib/Jifty/Plugin/OAuth/Dispatcher.pm	Wed Feb 20 19:30:29 2008
@@ -262,7 +262,7 @@
 
     $consumer->made_request(@oauth_params{qw/timestamp nonce/});
     Jifty->web->temporary_current_user(Jifty->app_class('CurrentUser')->new(id => $access_token->auth_as));
-    Jifty->web->current_user->is_oauthed(1);
+    Jifty->web->current_user->is_oauthed($access_token);
 }
 
 =head2 invalid_method

Modified: jifty/trunk/lib/Jifty/Plugin/OAuth/Model/Consumer.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Plugin/OAuth/Model/Consumer.pm	(original)
+++ jifty/trunk/lib/Jifty/Plugin/OAuth/Model/Consumer.pm	Wed Feb 20 19:30:29 2008
@@ -70,7 +70,7 @@
 
 sub before_set_last_timestamp {
     my $self = shift;
-    my $new_ts = shift;
+    my $new_ts = shift->{value};
 
     # uh oh, looks like sloppy coding..
     if ($new_ts < $self->last_timestamp) {


More information about the Jifty-commit mailing list