You are here

function hosting_server_post_hosting_delete_task in Hosting 7.4

Same name and namespace in other branches
  1. 7.3 server/hosting_server.drush.inc \hosting_server_post_hosting_delete_task()

Implements hook_post_hosting_TASK_TYPE_task().

File

server/hosting_server.drush.inc, line 86
:Drush hooks for the Hosting server module.

Code

function hosting_server_post_hosting_delete_task($task, $data) {
  if ($task->ref->type == 'server') {
    $task->ref->server_status = HOSTING_SERVER_DELETED;
    $task->ref->no_verify = TRUE;
    $task->ref->services = array();
    node_save($task->ref);
  }
  hosting_context_delete($task->ref->nid);
}