diff --git a/lib/Drupal/views/ViewStorage.php b/lib/Drupal/views/ViewStorage.php index a2ca757330dedb2617c577ac061eafc7c108a939..bb99de23c3d05b2c5c86b9aff461c8b9b8c44f40 100644 --- a/lib/Drupal/views/ViewStorage.php +++ b/lib/Drupal/views/ViewStorage.php @@ -9,7 +9,7 @@ use Drupal\config\ConfigurableBase; -class ViewStorage extends ConfigurableBase { +class ViewStorage extends ConfigurableBase implements ViewStorageInterface { public function __construct(array $values, $entity_type) { parent::__construct($values, 'view'); @@ -22,6 +22,27 @@ public function id() { return $this->name; } + /** + * Implements Drupal\views\ViewStorageInterface::enable(). + */ + public function enable() { + $this->disabled = FALSE; + } + + /** + * Implements Drupal\views\ViewStorageInterface::disable(). + */ + public function disable() { + $this->disabled = TRUE; + } + + /** + * Implements Drupal\views\ViewStorageInterface::isEnabled(). + */ + public function isEnabled() { + return !$this->disabled; + } + /** * Add a new display handler to the view, automatically creating an id. *