function subscriptions_og_og_membership_delete in Subscriptions 2.0.x
Same name and namespace in other branches
- 7 contrib/subscriptions_og/subscriptions_og.module \subscriptions_og_og_membership_delete()
Implements hook_og_membership_delete().
File
- subscriptions_og/
subscriptions_og.module, line 278 - Allow users to subscribe to content posted to an organic group.
Code
function subscriptions_og_og_membership_delete($og_membership) {
$autosubscribe = variable_get('subscriptions_og_autosubscribe', FALSE);
if ($autosubscribe && $og_membership->group_type == 'node' && $og_membership->entity_type == 'user') {
subscriptions_delete($og_membership->etid, 'node', 'group_audience', $og_membership->gid);
}
}