mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-07 21:42:16 -07:00
WIP: Checks the props for missing poster and deals with it accordingly (#221)
* Checks the props for missing poster and deals with it accordingly * Qucik fixes while trying to fix the Artist Poster index bug..
This commit is contained in:
parent
574e8ad36b
commit
c6873014c7
6 changed files with 22 additions and 3 deletions
|
@ -101,6 +101,7 @@ class AddNewArtist extends Component {
|
||||||
value={term}
|
value={term}
|
||||||
placeholder="eg. Breaking Benjamin, lidarr:854a1807-025b-42a8-ba8c-2a39717f1d25"
|
placeholder="eg. Breaking Benjamin, lidarr:854a1807-025b-42a8-ba8c-2a39717f1d25"
|
||||||
onChange={this.onSearchInputChange}
|
onChange={this.onSearchInputChange}
|
||||||
|
autoFocus={true}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
|
|
|
@ -69,6 +69,15 @@ class ArtistBanner extends Component {
|
||||||
// show the new image, whether an image was shown previously
|
// show the new image, whether an image was shown previously
|
||||||
// or the placeholder was shown.
|
// or the placeholder was shown.
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// The poster could not be loaded..
|
||||||
|
if (!nextBanner && (this.props !== prevProps)) {
|
||||||
|
this.setState({
|
||||||
|
banner: undefined,
|
||||||
|
bannerUrl: bannerPlaceholder,
|
||||||
|
hasError: true
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -70,6 +70,15 @@ class ArtistPoster extends Component {
|
||||||
// or the placeholder was shown.
|
// or the placeholder was shown.
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// The poster could not be loaded..
|
||||||
|
if (!nextPoster && (this.props !== prevProps)) {
|
||||||
|
this.setState({
|
||||||
|
poster: undefined,
|
||||||
|
posterUrl: posterPlaceholder,
|
||||||
|
hasError: true
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
|
@ -127,7 +127,7 @@ DeleteArtistModalContent.propTypes = {
|
||||||
artistName: PropTypes.string.isRequired,
|
artistName: PropTypes.string.isRequired,
|
||||||
path: PropTypes.string.isRequired,
|
path: PropTypes.string.isRequired,
|
||||||
trackFileCount: PropTypes.number.isRequired,
|
trackFileCount: PropTypes.number.isRequired,
|
||||||
sizeOnDisk: PropTypes.number.isRequired,
|
sizeOnDisk: PropTypes.number,
|
||||||
onDeletePress: PropTypes.func.isRequired,
|
onDeletePress: PropTypes.func.isRequired,
|
||||||
onModalClose: PropTypes.func.isRequired
|
onModalClose: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
|
|
@ -583,7 +583,7 @@ ArtistDetails.propTypes = {
|
||||||
artistName: PropTypes.string.isRequired,
|
artistName: PropTypes.string.isRequired,
|
||||||
ratings: PropTypes.object.isRequired,
|
ratings: PropTypes.object.isRequired,
|
||||||
path: PropTypes.string.isRequired,
|
path: PropTypes.string.isRequired,
|
||||||
sizeOnDisk: PropTypes.number.isRequired,
|
sizeOnDisk: PropTypes.number,
|
||||||
trackFileCount: PropTypes.number,
|
trackFileCount: PropTypes.number,
|
||||||
qualityProfileId: PropTypes.number.isRequired,
|
qualityProfileId: PropTypes.number.isRequired,
|
||||||
monitored: PropTypes.bool.isRequired,
|
monitored: PropTypes.bool.isRequired,
|
||||||
|
|
|
@ -103,7 +103,7 @@ ArtistIndexPosterInfo.propTypes = {
|
||||||
showQualityProfile: PropTypes.bool.isRequired,
|
showQualityProfile: PropTypes.bool.isRequired,
|
||||||
previousAiring: PropTypes.string,
|
previousAiring: PropTypes.string,
|
||||||
added: PropTypes.string,
|
added: PropTypes.string,
|
||||||
albumCount: PropTypes.number.isRequired,
|
albumCount: PropTypes.number,
|
||||||
path: PropTypes.string.isRequired,
|
path: PropTypes.string.isRequired,
|
||||||
sizeOnDisk: PropTypes.number,
|
sizeOnDisk: PropTypes.number,
|
||||||
sortKey: PropTypes.string.isRequired,
|
sortKey: PropTypes.string.isRequired,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue