1
0
mirror of https://github.com/strawberrymusicplayer/strawberry synced 2024-12-29 01:29:55 +01:00

Fix parsing Tidal track duration with Qt 6

This commit is contained in:
Jonas Kvinge 2020-08-06 15:58:53 +02:00
parent 0d820eda12
commit 276a34bb66

View File

@ -1034,7 +1034,7 @@ QString TidalRequest::ParseSong(Song &song, const QJsonObject &json_obj, const Q
QVariant q_duration = json_duration.toVariant();
quint64 duration = 0;
if (q_duration.isValid() && (q_duration.type() == QVariant::Int || q_duration.type() == QVariant::Double)) {
if (q_duration.isValid()) {
duration = q_duration.toLongLong() * kNsecPerSec;
}
else {