Make const
This commit is contained in:
@@ -1092,7 +1092,8 @@ QString TidalRequest::ParseSong(Song &song, const QJsonObject &json_obj, const Q
|
|||||||
|
|
||||||
void TidalRequest::GetAlbumCovers() {
|
void TidalRequest::GetAlbumCovers() {
|
||||||
|
|
||||||
for (Song &song : songs_) {
|
const SongList songs = songs_.values();
|
||||||
|
for (const Song &song : songs) {
|
||||||
AddAlbumCoverRequest(song);
|
AddAlbumCoverRequest(song);
|
||||||
}
|
}
|
||||||
FlushAlbumCoverRequests();
|
FlushAlbumCoverRequests();
|
||||||
@@ -1104,7 +1105,7 @@ void TidalRequest::GetAlbumCovers() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void TidalRequest::AddAlbumCoverRequest(Song &song) {
|
void TidalRequest::AddAlbumCoverRequest(const Song &song) {
|
||||||
|
|
||||||
if (album_covers_requests_sent_.contains(song.album_id())) {
|
if (album_covers_requests_sent_.contains(song.album_id())) {
|
||||||
album_covers_requests_sent_.insert(song.album_id(), song.song_id());
|
album_covers_requests_sent_.insert(song.album_id(), song.song_id());
|
||||||
|
|||||||
@@ -138,7 +138,7 @@ class TidalRequest : public TidalBaseRequest {
|
|||||||
QString ParseSong(Song &song, const QJsonObject &json_obj, const QString &artist_id_requested = QString(), const QString &album_id_requested = QString(), const QString &album_artist = QString(), const QString &album_album = QString(), const bool album_explicit = false);
|
QString ParseSong(Song &song, const QJsonObject &json_obj, const QString &artist_id_requested = QString(), const QString &album_id_requested = QString(), const QString &album_artist = QString(), const QString &album_album = QString(), const bool album_explicit = false);
|
||||||
|
|
||||||
void GetAlbumCovers();
|
void GetAlbumCovers();
|
||||||
void AddAlbumCoverRequest(Song &song);
|
void AddAlbumCoverRequest(const Song &song);
|
||||||
void FlushAlbumCoverRequests();
|
void FlushAlbumCoverRequests();
|
||||||
void AlbumCoverFinishCheck();
|
void AlbumCoverFinishCheck();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user