Skip to content
Snippets Groups Projects
Commit 60fa9536 authored by Aliaksei Bykouski's avatar Aliaksei Bykouski Committed by Alexander Shumenko
Browse files

Issue #3407023 by eyeless: CacheBlockForm class prevents configuration changes...

Issue #3407023 by eyeless: CacheBlockForm class prevents configuration changes from saving in block plugins
parent 1f738453
No related branches found
No related tags found
No related merge requests found
......@@ -156,11 +156,11 @@ class CacheBlockForm extends BlockForm {
public function submitForm(array &$form, FormStateInterface $form_state) {
parent::submitForm($form, $form_state);
$block = $this->getEntity();
$plugin = $this->getEntity()->getPlugin();
$config = $plugin->getConfiguration();
$adv_varnish = $form_state->getValue('settings')['adv_varnish'];
$settings = $block->get('settings');
$settings['cache'] = $adv_varnish['cache'];
$block->set('settings', $settings);
$config['cache'] = $adv_varnish['cache'];
$plugin->setConfiguration($config);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment