public function onConfigSave(ConfigCrudEvent
$event) { $config =
$event->
getConfig();
if ($config->
getName() == 'automated_cron.settings'
) { $values =
$this->state->
get('ConfigImportUITest.automated_cron.settings.interval',
[]);
$values[] =
$config->
get('interval'
);
$this->state->
set('ConfigImportUITest.automated_cron.settings.interval',
$values);
} if ($config->
getName() == 'core.extension'
) { $installed =
$this->state->
get('ConfigImportUITest.core.extension.modules_installed',
[]);
$uninstalled =
$this->state->
get('ConfigImportUITest.core.extension.modules_uninstalled',
[]);
$original =
$config->
getOriginal('module'
);
$data =
$config->
get('module'
);
$install =
array_diff_key($data,
$original);
if (!
empty($install)) { $installed[] =
key($install);
} $uninstall =
array_diff_key($original,
$data);
if (!
empty($uninstall)) { $uninstalled[] =
key($uninstall);
} $this->state->
set('ConfigImportUITest.core.extension.modules_installed',
$installed);