public function FieldCollectionType::setConfiguration

Overrides DrupalSqlBase::setConfiguration

Deprecated

addDescription configuration key is deprecated in 8.x-1.0 and will be removed prior to 9.x. Use add_description instead.

See also

https://www.drupal.org/project/paragraphs/issues/2911242

File

paragraphs/src/Plugin/migrate/source/d7/FieldCollectionType.php, line 98

Class

FieldCollectionType
Field Collection Type source plugin.

Namespace

Drupal\paragraphs\Plugin\migrate\source\d7

Code

public function setConfiguration(array $configuration) {

  // Configuration keys should be snake_case, not CamelCase. Adding a BC
  // layer for addDescription which should be deprecated.
  if (isset($configuration['addDescription'])) {
    @trigger_error("addDescription configuration key is deprecated in 8.x-1.0 and will be removed prior to 9.x.  Use add_description instead. See https://www.drupal.org/project/paragraphs/issues/2911242", E_USER_DEPRECATED);
    if (!isset($configuration['add_description'])) {
      $configuration['add_description'] = $configuration['addDescription'];
    }
    unset($configuration['addDescription']);
  }
  parent::setConfiguration($configuration);
}