Update stream url to avoid requesting it twice

This commit is contained in:
Jonas Kvinge 2020-09-29 23:03:50 +02:00
parent 938ee20f1f
commit b81cfa8acb
1 changed files with 4 additions and 0 deletions

View File

@ -748,7 +748,11 @@ void Player::TrackAboutToEnd() {
loading_async_ << url;
return;
case UrlHandler::LoadResult::TrackAvailable:
qLog(Debug) << "URL handler for" << result.original_url_ << "returned" << result.stream_url_;
url = result.stream_url_;
Song song = next_item->Metadata();
song.set_stream_url(url);
next_item->SetTemporaryMetadata(song);
break;
}
}