Use QJsonValueRef
This commit is contained in:
@@ -396,12 +396,12 @@ void QobuzRequest::ArtistsReplyReceived(QNetworkReply *reply, const int limit_re
|
||||
}
|
||||
|
||||
int artists_received = 0;
|
||||
for (const QJsonValue value_item : array_items) {
|
||||
for (const QJsonValueRef value_item : array_items) {
|
||||
|
||||
++artists_received;
|
||||
|
||||
if (!value_item.isObject()) {
|
||||
Error("Invalid Json reply, item not a object.", value_item);
|
||||
Error("Invalid Json reply, item not a object.");
|
||||
continue;
|
||||
}
|
||||
QJsonObject obj_item = value_item.toObject();
|
||||
@@ -609,12 +609,12 @@ void QobuzRequest::AlbumsReceived(QNetworkReply *reply, const QString &artist_id
|
||||
}
|
||||
|
||||
int albums_received = 0;
|
||||
for (const QJsonValue value : array_items) {
|
||||
for (const QJsonValueRef value : array_items) {
|
||||
|
||||
++albums_received;
|
||||
|
||||
if (!value.isObject()) {
|
||||
Error("Invalid Json reply, item not a object.", value);
|
||||
Error("Invalid Json reply, item not a object.");
|
||||
continue;
|
||||
}
|
||||
QJsonObject obj_item = value.toObject();
|
||||
@@ -907,10 +907,10 @@ void QobuzRequest::SongsReceived(QNetworkReply *reply, const QString &artist_id_
|
||||
//bool multidisc = false;
|
||||
SongList songs;
|
||||
int songs_received = 0;
|
||||
for (const QJsonValue value_item : array_items) {
|
||||
for (const QJsonValueRef value_item : array_items) {
|
||||
|
||||
if (!value_item.isObject()) {
|
||||
Error("Invalid Json reply, track is not a object.", value_item);
|
||||
Error("Invalid Json reply, track is not a object.");
|
||||
continue;
|
||||
}
|
||||
QJsonObject obj_item = value_item.toObject();
|
||||
|
||||
Reference in New Issue
Block a user