Browse Source

Drupal 9 compatibility fixes.

8.x-1.x
Alexander O'Neill 4 years ago
parent
commit
20118f0b3f
  1. 2
      media_attribution.info.yml
  2. 3
      media_attribution.module

2
media_attribution.info.yml

@ -1,7 +1,7 @@
name: 'Media Attribution' name: 'Media Attribution'
type: module type: module
description: 'Attach attribution and license info to media entities.' description: 'Attach attribution and license info to media entities.'
core: 8.x core_version_requirement: ^8 || ^9
package: 'media' package: 'media'
dependencies: dependencies:
- drupal:media - drupal:media

3
media_attribution.module

@ -59,6 +59,7 @@ function media_attribution_modules_installed($modules) {
'collapse_edit_all' => 'collapse_edit_all', 'collapse_edit_all' => 'collapse_edit_all',
] ]
], ],
'weight' => 35,
'type' => 'paragraphs', 'type' => 'paragraphs',
]) ])
->save(); ->save();
@ -70,7 +71,7 @@ function media_attribution_modules_installed($modules) {
$view_entity->setComponent('field_image_attribution', [ $view_entity->setComponent('field_image_attribution', [
'type' => 'entity_reference_revisions_entity_view', 'type' => 'entity_reference_revisions_entity_view',
'label' => 'hidden', 'label' => 'hidden',
'settings' => ['view_mode' => 'default', 'link' => ''], 'settings' => ['view_mode' => 'license_attribution', 'link' => ''],
])->save(); ])->save();
} }
} }

Loading…
Cancel
Save