[Rt-commit] rt branch, admin_ui, updated. 1f3b3e3d731cb5c7573b47e495201995c4cc4d11

sunnavy at bestpractical.com sunnavy at bestpractical.com
Thu Jan 21 02:29:16 EST 2010


The branch, admin_ui has been updated
       via  1f3b3e3d731cb5c7573b47e495201995c4cc4d11 (commit)
      from  e360f369e375b7734f010244868929bd93ea6409 (commit)

Summary of changes:
 lib/RT/Action/EditUserPrefsOther.pm |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

- Log -----------------------------------------------------------------
commit 1f3b3e3d731cb5c7573b47e495201995c4cc4d11
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Thu Jan 21 15:29:08 2010 +0800

    tiny tweak

diff --git a/lib/RT/Action/EditUserPrefsOther.pm b/lib/RT/Action/EditUserPrefsOther.pm
index 2017b28..9eace40 100644
--- a/lib/RT/Action/EditUserPrefsOther.pm
+++ b/lib/RT/Action/EditUserPrefsOther.pm
@@ -213,8 +213,7 @@ use Jifty::Action schema {
 sub take_action {
     my $self = shift;
 
-    my $user = Jifty->web->current_user->user_object;
-    my $pref = $user->preferences( $self->name ) || {};
+    my $pref = $self->user->preferences( $self->name ) || {};
     for my $arg ( $self->argument_names ) {
         if ( $self->has_argument($arg) ) {
             if ( $arg eq 'preferred_key' ) {
@@ -232,7 +231,7 @@ sub take_action {
             }
         }
     }
-    my ( $status, $msg ) = $user->set_preferences( $self->name, $pref );
+    my ( $status, $msg ) = $self->user->set_preferences( $self->name, $pref );
     Jifty->log->error($msg) unless $status;
     $self->report_success;
 

-----------------------------------------------------------------------


More information about the Rt-commit mailing list