You are here

public function ConfigActionsList::doSave in Config Actions 8

Save data to the source.

Parameters

array $data:

Return value

bool TRUE if the data was saved.

Overrides ConfigActionsSourceBase::doSave

File

src/Plugin/ConfigActionsSource/ConfigActionsList.php, line 53

Class

ConfigActionsList
Plugin for handling a list of source locations.

Namespace

Drupal\config_actions\Plugin\ConfigActionsSource

Code

public function doSave($data) {
  $result = FALSE;

  // Loop through sources and pick first success
  foreach ($this->sourceId as $source) {
    $result = $this->actionService
      ->saveSource($data, $source, '', $this->sourceBase);
    if ($result) {
      break;
    }
  }
  return $result;
}