You are here

function nodequeue_nodequeue_add in Nodequeue 7.2

Implements hook_nodequeue_add()

File

./nodequeue.module, line 2496
Maintains queues of nodes in arbitrary order.

Code

function nodequeue_nodequeue_add($sqid, $nid) {
  if (module_exists('rules')) {

    // When a node is added to a nodequeue invoke the corresponding rules event
    $subqueue = nodequeue_load_subqueue($sqid);
    $node = node_load($nid);
    rules_invoke_event('nodequeue_added', $subqueue, $node);
    rules_invoke_event('nodequeue_saved', $subqueue, $node);
  }
}