1
0
mirror of https://github.com/Radarr/Radarr.git synced 2024-07-02 10:22:21 +02:00

Fallback to remote url for backdrop image

This commit is contained in:
Bogdan 2024-06-10 14:21:50 +03:00
parent 69ad0caf40
commit a8eea20d69

View File

@ -1,4 +1,3 @@
import _ from 'lodash';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import TextTruncate from 'react-text-truncate';
@ -51,7 +50,8 @@ const defaultFontSize = parseInt(fonts.defaultFontSize);
const lineHeight = parseFloat(fonts.lineHeight);
function getFanartUrl(images) {
return _.find(images, { coverType: 'fanart' })?.url;
const image = images.find((img) => img.coverType === 'fanart');
return image?.url ?? image?.remoteUrl;
}
class MovieDetails extends Component {