Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / lib / Drupal / Core / Entity / EntityPublishedTrait.php
index eb4d82e89b8eee87af38c0b3967c3030448b3ed8..1f36625828e53c308f464ea39725609246744c42 100644 (file)
@@ -45,8 +45,7 @@ trait EntityPublishedTrait {
    * {@inheritdoc}
    */
   public function isPublished() {
-    $key = $this->getEntityType()->getKey('published');
-    return (bool) $this->get($key)->value;
+    return (bool) $this->getEntityKey('published');
   }
 
   /**