function redhen_engagement_redhen_contact_delete in RedHen CRM 7
Implements hook_ENTITY_TYPE_delete().
File
- modules/
redhen_engagement/ redhen_engagement.module, line 438 - RedhenEngagement hook implementations and API
Code
function redhen_engagement_redhen_contact_delete(RedhenContact $contact) {
// Delete engagements when the parent contact is deleted.
db_delete('redhen_engagement')
->condition('contact_id', $contact->contact_id)
->execute();
}