Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pending and Blocked users are not removed on user delete. #740

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion plugins/entityreference/behavior/OgBehaviorHandler.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ public function delete($entity_type, $entity, $field, $instance, $langcode, &$it
if (!empty($entity->delete_og_membership)) {
// Delete all OG memberships related to this entity.
$og_memberships = array();
foreach (og_get_entity_groups($entity_type, $entity) as $group_type => $ids) {
$groups = og_get_entity_groups($entity_type, $entity, array(OG_STATE_ACTIVE, OG_STATE_PENDING, OG_STATE_BLOCKED));
MPParsley marked this conversation as resolved.
Show resolved Hide resolved
foreach ($groups as $group_type => $ids) {
$og_memberships = array_merge($og_memberships, array_keys($ids));
}
if ($og_memberships) {
Expand Down