|
|
@ -107,10 +107,10 @@ function media_attribution_preprocess_entity_embed_container(&$variables) { |
|
|
|
$attribution = $attributions[0]; |
|
|
|
$attribution = $attributions[0]; |
|
|
|
$author = $attribution->get('field_attribution_author')->getValue()[0]; |
|
|
|
$author = $attribution->get('field_attribution_author')->getValue()[0]; |
|
|
|
|
|
|
|
|
|
|
|
$source = $attribution->get('field_attribution_source')->getValue()[0]; |
|
|
|
$source = $attribution->get('field_attribution_source')->count() > 0 ? $attribution->get('field_attribution_source')->getValue()[0] : ''; |
|
|
|
$license = $attribution->get('field_license')->entity; |
|
|
|
$license = $attribution->get('field_license')->entity; |
|
|
|
$license_link = !empty($license) ? $license->get('field_license_link')->getValue()[0] : FALSE; |
|
|
|
$license_link = !empty($license) ? $license->get('field_license_link')->getValue()[0] : FALSE; |
|
|
|
$attribution_note = $attribution->get('field_attribution_note')->getValue()[0]; |
|
|
|
$attribution_note = $attribution->get('field_attribution_note')->count() > 0 ? $attribution->get('field_attribution_note')->getValue()[0]: ''; |
|
|
|
$attribution_text = []; |
|
|
|
$attribution_text = []; |
|
|
|
if (!empty($source['uri'])) { |
|
|
|
if (!empty($source['uri'])) { |
|
|
|
$attribution_text['source'] = [ |
|
|
|
$attribution_text['source'] = [ |
|
|
|