When Group->new is called with a group that doesn't exist, it returns a faked Group object. Calling delete on this object fails for some Cache types.
This commit is contained in:
parent
981ab43984
commit
2ec38b1407
2 changed files with 3 additions and 1 deletions
|
|
@ -277,7 +277,8 @@ sub clearCaches {
|
|||
my $session = $self->session;
|
||||
##Clear my cache and the cache of all groups above me.
|
||||
my $groups = $self->getAllGroupsFor();
|
||||
foreach my $groupId ( $self->getId, @{ $groups } ) {
|
||||
GROUPID: foreach my $groupId ( $self->getId, @{ $groups } ) {
|
||||
next GROUPID if !$groupId;
|
||||
WebGUI::Cache->new($session, $groupId)->delete;
|
||||
WebGUI::Cache->new($session, ["groupMembers", $groupId])->delete;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue