You are here

public function SocialPostPhotoAlbumConfigOverride::loadOverrides in Open Social 10.3.x

Same name and namespace in other branches
  1. 10.0.x modules/social_features/social_post/modules/social_post_album/src/SocialPostPhotoAlbumConfigOverride.php \Drupal\social_post_album\SocialPostPhotoAlbumConfigOverride::loadOverrides()
  2. 10.1.x modules/social_features/social_post/modules/social_post_album/src/SocialPostPhotoAlbumConfigOverride.php \Drupal\social_post_album\SocialPostPhotoAlbumConfigOverride::loadOverrides()
  3. 10.2.x modules/social_features/social_post/modules/social_post_album/src/SocialPostPhotoAlbumConfigOverride.php \Drupal\social_post_album\SocialPostPhotoAlbumConfigOverride::loadOverrides()

Returns config overrides.

Parameters

array $names: A list of configuration names that are being loaded.

Return value

array An array keyed by configuration name of override data. Override data contains a nested array structure of overrides.

Overrides ConfigFactoryOverrideInterface::loadOverrides

File

modules/social_features/social_post/modules/social_post_album/src/SocialPostPhotoAlbumConfigOverride.php, line 27

Class

SocialPostPhotoAlbumConfigOverride
Provides an overridden elements.

Namespace

Drupal\social_post_album

Code

public function loadOverrides($names) {
  $overrides = [];
  foreach (self::TYPES as $config_name => $type) {
    if (in_array($config_name, $names)) {
      $overrides[$config_name]['content']['field_post_image']['type'] = $type;
    }
  }
  return $overrides;
}