Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / node / src / Plugin / Action / UnpublishByKeywordNode.php
index 3709853335a20a0ca761639956e3e50041f8c4e2..91b60c204a223743d2f480b265680e73ec37546f 100644 (file)
@@ -25,7 +25,7 @@ class UnpublishByKeywordNode extends ConfigurableActionBase {
     foreach ($this->configuration['keywords'] as $keyword) {
       $elements = node_view(clone $node);
       if (strpos(\Drupal::service('renderer')->render($elements), $keyword) !== FALSE || strpos($node->label(), $keyword) !== FALSE) {
-        $node->setPublished(FALSE);
+        $node->setUnpublished();
         $node->save();
         break;
       }