function hosting_platform_post_hosting_delete_task in Hosting 6.2
Same name and namespace in other branches
- 7.4 platform/hosting_platform.drush.inc \hosting_platform_post_hosting_delete_task()
- 7.3 platform/hosting_platform.drush.inc \hosting_platform_post_hosting_delete_task()
Implementation of hook_hosting_post_DELETE().
File
- platform/
hosting_platform.drush.inc, line 106 - Implement drush hooks for the Platforms module.
Code
function hosting_platform_post_hosting_delete_task($task, $data) {
$task->ref->platform_status = HOSTING_PLATFORM_DELETED;
$task->ref->no_verify = TRUE;
node_save($task->ref);
hosting_context_delete($task->ref->nid);
db_query("DELETE FROM {hosting_platform_client_access} WHERE pid = %d", $task->ref->nid);
// Clean up package instances
hosting_package_instance_sync($task->ref->nid, 'platform');
}