diff --git a/addons/nodequeue_rules/nodequeue_rules.rules.inc b/addons/nodequeue_rules/nodequeue_rules.rules.inc index 2b8eff8..ac208a0 100644 --- a/addons/nodequeue_rules/nodequeue_rules.rules.inc +++ b/addons/nodequeue_rules/nodequeue_rules.rules.inc @@ -33,7 +33,7 @@ function nodequeue_rules_rules_condition_info() { /** * The callback for the condition 'nodequeue_rules_node_in_queue' */ -function nodequeue_rules_node_in_queue($queue, $node) { +function nodequeue_rules_node_in_queue($queue_name, $node) { // Note that the order of the parameters is the same as in the declaration of // the condition. Use the same variable names as in the declaration to avoid // confusion. @@ -46,7 +46,7 @@ function nodequeue_rules_node_in_queue($queue, $node) { ->fetchAssoc(); // All conditions return TRUE or FALSE. // fetchAssoc returns false if no row is found; use implicit truthiness get around that case. - return $fetchAssoc() && ($queue->qid == $node_in_queue['qid']) ? TRUE : FALSE; + return $node_in_queue && ($queue->qid == $node_in_queue['qid']) ? TRUE : FALSE; } /**