You are here

public function FeedsConfigurable::addConfig in Feeds 8.2

Similar to setConfig but adds to existing configuration.

Parameters

$config: Array containing configuration information. Will be filtered by the keys returned by configDefaults().

1 call to FeedsConfigurable::addConfig()
FeedsConfigurable::configFormSubmit in lib/Drupal/feeds/Plugin/FeedsConfigurable.php
Submission handler for configForm().

File

lib/Drupal/feeds/Plugin/FeedsConfigurable.php, line 138
FeedsConfigurable and helper functions.

Class

FeedsConfigurable
Base class for configurable classes. Captures configuration handling, form handling and distinguishes between in-memory configuration and persistent configuration.

Namespace

Drupal\feeds\Plugin

Code

public function addConfig($config) {
  $this->config = is_array($this->config) ? array_merge($this->config, $config) : $config;
  $default_keys = $this
    ->configDefaults();
  $this->config = array_intersect_key($this->config, $default_keys);
}