[Bps-public-commit] rt-authen-externalauth branch, dont-disable-disabled-user, updated. 0.09-3-g7e8cd27

Kevin Falcone falcone at bestpractical.com
Mon Sep 19 14:21:26 EDT 2011


The branch, dont-disable-disabled-user has been updated
       via  7e8cd27ec573690029655777c9d3f4857c181806 (commit)
       via  ceba1c5211aeb0d2f3e515627b100cadd232a822 (commit)
      from  4b69d20873581110ea3d50ac999ac4aa65bd75f4 (commit)

Summary of changes:
 lib/RT/Authen/ExternalAuth.pm |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

- Log -----------------------------------------------------------------
commit ceba1c5211aeb0d2f3e515627b100cadd232a822
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Mon Sep 19 14:13:54 2011 -0400

    Principal not Principle

diff --git a/lib/RT/Authen/ExternalAuth.pm b/lib/RT/Authen/ExternalAuth.pm
index e746b61..3615734 100644
--- a/lib/RT/Authen/ExternalAuth.pm
+++ b/lib/RT/Authen/ExternalAuth.pm
@@ -246,7 +246,7 @@ sub UpdateUserInfo {
     my $UserObj = RT::User->new($RT::SystemUser);
     $UserObj->Load($username);        
 
-    # If user is disabled, set the RT::Principle to disabled and return out of the function.
+    # If user is disabled, set the RT::Principal to disabled and return out of the function.
     # I think it's a waste of time and energy to update a user's information if they are disabled
     # and it could be a security risk if they've updated their external information with some 
     # carefully concocted code to try to break RT - worst case scenario, but they have been 
@@ -257,7 +257,7 @@ sub UpdateUserInfo {
 
     if ($user_disabled) {
         unless ( $UserObj->Disabled ) {
-            # Make sure principle is disabled in RT
+            # Make sure principal is disabled in RT
             my ($val, $message) = $UserObj->SetDisabled(1);
             # Log what has happened
             $RT::Logger->info("User marked as DISABLED (",
@@ -270,7 +270,7 @@ sub UpdateUserInfo {
         return ($updated, $msg);
     }    
         
-    # Make sure principle is not disabled in RT
+    # Make sure principal is not disabled in RT
     if ( $UserObj->Disabled ) {
         my ($val, $message) = $UserObj->SetDisabled(0);
         unless ( $val ) {

commit 7e8cd27ec573690029655777c9d3f4857c181806
Author: Kevin Falcone <falcone at bestpractical.com>
Date:   Mon Sep 19 14:20:14 2011 -0400

    Andrew Daugherity notes that SetDisabled(0) can return an undef message

diff --git a/lib/RT/Authen/ExternalAuth.pm b/lib/RT/Authen/ExternalAuth.pm
index 3615734..179939c 100644
--- a/lib/RT/Authen/ExternalAuth.pm
+++ b/lib/RT/Authen/ExternalAuth.pm
@@ -274,7 +274,7 @@ sub UpdateUserInfo {
     if ( $UserObj->Disabled ) {
         my ($val, $message) = $UserObj->SetDisabled(0);
         unless ( $val ) {
-            $RT::Logger->error("Failed to enable user ($username) per External Service: $message");
+            $RT::Logger->error("Failed to enable user ($username) per External Service: ".($message||''));
             return ($updated, "Failed to enable");
         }
 

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



More information about the Bps-public-commit mailing list