Commit fba6dda0 authored by pfrenssen's avatar pfrenssen

Fix notice when trying to access a membership that was just deleted.

parent 26955851
......@@ -3556,7 +3556,9 @@ function og_get_groups_by_user($account = NULL, $group_type = NULL) {
}
foreach ($og_memberships as $og_membership) {
$gids[$og_membership->group_type][$og_membership->gid] = $og_membership->gid;
if (!empty($og_membership)) {
$gids[$og_membership->group_type][$og_membership->gid] = $og_membership->gid;
}
}
if (empty($group_type)) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment