[Rt-commit] rt branch, 4.2/migrator-fixes, updated. rt-4.2.12-115-g3a2fb8e

Shawn Moore shawn at bestpractical.com
Sat Mar 12 13:10:44 EST 2016


The branch, 4.2/migrator-fixes has been updated
       via  3a2fb8e90e57f7447a33e327e3c8aa63b58e59f4 (commit)
      from  152c90c600c19cf470e9202b21b1cbb82a100072 (commit)

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

- Log -----------------------------------------------------------------
commit 3a2fb8e90e57f7447a33e327e3c8aa63b58e59f4
Author: Shawn M Moore <shawn at bestpractical.com>
Date:   Sat Mar 12 18:03:31 2016 +0000

    Fix for importing ACLs granted to users
    
        Before this fix, importing ACLs from another system correctly
        maintained rights granted to groups, but not those granted to
        users. This is because when we inflate the ACLEquivalence
        UserEquiv group for that user, we change its name to handle the
        change in the user's ID.
    
        However, ACLEquivalence UserEquiv groups have not used user ID
        in their name since 71fcde32, which is when this regression was
        introduced.
    
        The admin pages for user rights issue a query where
        the ACLEquivalence group name is expected to be "UserEquiv" but
        the importer code was changing the name from UserEquiv to be
        e.g. "User 99". So it wasn't finding or listing the ACL entries.
    
    Fixes: I#31806

diff --git a/lib/RT/Group.pm b/lib/RT/Group.pm
index c412ba6..81ac325 100644
--- a/lib/RT/Group.pm
+++ b/lib/RT/Group.pm
@@ -1741,13 +1741,12 @@ sub PreInflate {
         return;
     };
 
-    # Go looking for the pre-existing version of the it
+    # Go looking for the pre-existing version of it
     if ($data->{Domain} eq "ACLEquivalence") {
         $obj->LoadACLEquivalenceGroup( $data->{Instance} );
         return $duplicated->() if $obj->Id;
 
-        # Update the name and description for the new ID
-        $data->{Name} = 'User '. $data->{Instance};
+        # Update description for the new ID
         $data->{Description} = 'ACL equiv. for user '.$data->{Instance};
     } elsif ($data->{Domain} eq "UserDefined") {
         $data->{Name} = $importer->Qualify($data->{Name});

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


More information about the rt-commit mailing list