function NodeIsPublished::doEvaluate

Checks if a node is published.

Parameters

\Drupal\node\NodeInterface $node: The node to check.

Return value

bool TRUE if the node is published.

File

src/Plugin/Condition/NodeIsPublished.php, line 37

Class

NodeIsPublished
Provides a 'Node is published' condition.

Namespace

Drupal\rules\Plugin\Condition

Code

protected function doEvaluate(NodeInterface $node) {
    return $node->isPublished();
}