Skip to content
Snippets Groups Projects

Issue #3371632: Change thumbnail logic

1 file
+ 8
1
Compare changes
  • Side-by-side
  • Inline
@@ -191,7 +191,14 @@ final class Xymatic extends MediaSourceBase {
return parent::getMetadata($media, 'default_name');
case 'thumbnail_uri':
$posterImage = !empty($json['inputPosters']) ? end($json['inputPosters']) : [];
$posterImage = [];
if ($json['posterType'] === 'CUSTOM_POSTER' && !empty($json['poster'])) {
$posterImage = end($json['poster']);
}
elseif (!empty($json['posterRenditions'])) {
$posterImage = end($json['posterRenditions']);
}
return $this->getLocalThumbnailUri($posterImage) ?: parent::getMetadata($media, 'thumbnail_uri');
case 'nudeContent':
Loading