Remove debug code from Group.t
Force uniqueness check inside isInGroups to prevent multiple group definitions from being returned. This should cut the size of the in-memory Group cache by 50%, since group id #3 is returned for _every_ group.
This commit is contained in:
parent
7f7347faa9
commit
c6b0d9b8d5
2 changed files with 2 additions and 9 deletions
|
|
@ -494,7 +494,6 @@ not ever manually set this.
|
|||
|
||||
=cut
|
||||
|
||||
|
||||
sub getGroupsIn {
|
||||
my $self = shift;
|
||||
my $isRecursive = shift;
|
||||
|
|
@ -516,6 +515,8 @@ sub getGroupsIn {
|
|||
my $gog = WebGUI::Group->new($self->session,$group)->getGroupsIn(1,$loopCount);
|
||||
push(@groupsOfGroups, @$gog);
|
||||
}
|
||||
my %unique = map { $_ => 1 } @groupsOfGroups;
|
||||
@groupsOfGroups = keys %unique;
|
||||
$gotGroupsInGroup->{recursive}{$self->getId} = \@groupsOfGroups;
|
||||
return \@groupsOfGroups;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue