function og_notifications_nodeapi in Organic groups 5
Same name and namespace in other branches
- 5.8 og_notifications/og_notifications.module \og_notifications_nodeapi()
- 5.3 og_notifications/og_notifications.module \og_notifications_nodeapi()
- 5.7 og_notifications/og_notifications.module \og_notifications_nodeapi()
- 6.2 modules/og_notifications/og_notifications.module \og_notifications_nodeapi()
- 6 modules/og_notifications/og_notifications.module \og_notifications_nodeapi()
Implementation of hook_nodeapi()
File
- og_notifications/
og_notifications.module, line 110 - Subscriptions to content in groups.
Code
function og_notifications_nodeapi(&$node, $op, $arg = 0) {
switch ($op) {
case 'delete':
// Remove all group subscriptions for this node
notifications_delete_subscriptions(array(
'type' => 'group',
), array(
'group' => $node->nid,
));
notifications_delete_subscriptions(array(
'type' => 'grouptype',
), array(
'group' => $node->nid,
));
}
}