Fixing broken artist play button

This commit is contained in:
James Barnsley
2017-11-15 21:08:45 +13:00
parent 0fc5a82cf0
commit 41c7fed44e

View File

@ -216,8 +216,9 @@ class Artist extends React.Component{
if (this.props.artist){
var is_spotify = (scheme == 'spotify')
if (is_spotify){
var uris_to_play = (this.props.artist.tracks ? helpers.arrayOf('uri', this.props.artist.tracks) : [])
if (this.props.artist.tracks_uris && this.props.artist.tracks_uris.length > 0){
var uris_to_play = this.props.artist.tracks_uris
} else {
var uris_to_play = this.props.artist.albums_uris
}