You are here

function drush_hosting_post_hosting_task in Hosting 7.4

Same name and namespace in other branches
  1. 5 task.hosting.inc \drush_hosting_post_hosting_task()
  2. 6.2 task.hosting.inc \drush_hosting_post_hosting_task()
  3. 7.3 task.hosting.inc \drush_hosting_post_hosting_task()

Post completion hook for the hosting-task Drush command.

Used primarily to trigger hosting_context_delete() for site, platform and server nodes, but only AFTER the task has completed successfully.

See also

hook_post_hosting_TASK_TYPE_task()

File

./task.hosting.inc, line 609
Drush include for the Hosting module's hosting task command.

Code

function drush_hosting_post_hosting_task($task) {
  $task =& drush_get_context('HOSTING_TASK');
  $hook = sprintf("post_hosting_%s_task", str_replace('-', '_', $task->task_type));
  drush_log(dt('Invoking :hook hooks.', array(
    ':hook' => $hook,
  )));
  module_invoke_all($hook, $task, drush_get_context('HOSTING_DRUSH_OUTPUT'));
}