function domain_domainupdate in Domain Access 7.2
Same name and namespace in other branches
- 5 domain.module \domain_domainupdate()
- 6.2 domain.module \domain_domainupdate()
Implements hook_domainupdate()
@TODO: reassign orphans?
File
- ./
domain.module, line 2593 - Core module functions for the Domain Access suite.
Code
function domain_domainupdate($op, $domain, $form_state = array()) {
switch ($op) {
case 'delete':
if ($domain != -1) {
// Remove domain-specific entries from tables and clear the cache.
db_delete('domain_access')
->condition('gid', $domain['domain_id'])
->condition('realm', 'domain_id')
->execute();
db_delete('domain_editor')
->condition('domain_id', $domain['domain_id'])
->execute();
}
break;
}
// In all cases, we need to force a menu rebuild, which also clears the cache.
menu_rebuild();
}