You are here

protected function NodeIsScheduledForPublishing::doEvaluate in Scheduler 8

Determines whether a node is scheduled for publishing.

Return value

bool TRUE if the node is scheduled for publishing, FALSE if not.

File

scheduler_rules_integration/src/Plugin/Condition/NodeIsScheduledForPublishing.php, line 30

Class

NodeIsScheduledForPublishing
Provides 'Node is scheduled for publishing' condition.

Namespace

Drupal\scheduler_rules_integration\Plugin\Condition

Code

protected function doEvaluate() {
  $node = $this
    ->getContextValue('node');
  return !empty($node->publish_on->value);
}