function ConfigSnapshotSubscriber::onConfigImporterImport

Same name in other branches
  1. 9 core/lib/Drupal/Core/EventSubscriber/ConfigSnapshotSubscriber.php \Drupal\Core\EventSubscriber\ConfigSnapshotSubscriber::onConfigImporterImport()
  2. 8.9.x core/lib/Drupal/Core/EventSubscriber/ConfigSnapshotSubscriber.php \Drupal\Core\EventSubscriber\ConfigSnapshotSubscriber::onConfigImporterImport()
  3. 11.x core/lib/Drupal/Core/EventSubscriber/ConfigSnapshotSubscriber.php \Drupal\Core\EventSubscriber\ConfigSnapshotSubscriber::onConfigImporterImport()

Creates a config snapshot.

Parameters

\Drupal\Core\Config\ConfigImporterEvent $event: The Event to process.

File

core/lib/Drupal/Core/EventSubscriber/ConfigSnapshotSubscriber.php, line 59

Class

ConfigSnapshotSubscriber
Create a snapshot when config is imported.

Namespace

Drupal\Core\EventSubscriber

Code

public function onConfigImporterImport(ConfigImporterEvent $event) {
    $this->configManager
        ->createSnapshot($this->sourceStorage, $this->snapshotStorage);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.