You are here

public function QueueUISystemQueue::release in Queue UI 7.2

Force the releasing of a specified queue item.

Parameters

integer $item_id: The item id to be released.

Return value

TRUE if releasing succeeds, FALSE if releasing fails.

Overrides QueueUIInterface::release

File

lib/QueueUISystemQueue.php, line 136

Class

QueueUISystemQueue

Code

public function release($item_id) {

  // @TODO - try... catch...
  drupal_set_message("Released queue item " . $item_id);
  db_update('queue')
    ->condition('item_id', $item_id)
    ->fields(array(
    'expire' => 0,
  ))
    ->execute();
  return TRUE;
}