From 32ae3cd567fab9632aa196f85423fd965ca4c27b Mon Sep 17 00:00:00 2001 From: Jonas Kvinge Date: Sun, 20 Dec 2020 07:24:44 +0100 Subject: [PATCH] QNetworkRequest::Http2AllowedAttribute require Qt 5.14 --- src/covermanager/musixmatchcoverprovider.cpp | 2 ++ src/lyrics/musixmatchlyricsprovider.cpp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/covermanager/musixmatchcoverprovider.cpp b/src/covermanager/musixmatchcoverprovider.cpp index 99069e097..69fe22caf 100644 --- a/src/covermanager/musixmatchcoverprovider.cpp +++ b/src/covermanager/musixmatchcoverprovider.cpp @@ -83,7 +83,9 @@ bool MusixmatchCoverProvider::StartSearch(const QString &artist, const QString & #else req.setAttribute(QNetworkRequest::FollowRedirectsAttribute, true); #endif +#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0) req.setAttribute(QNetworkRequest::Http2AllowedAttribute, false); +#endif QNetworkReply *reply = network_->get(req); replies_ << reply; connect(reply, &QNetworkReply::finished, [=] { HandleSearchReply(reply, id, artist, album); }); diff --git a/src/lyrics/musixmatchlyricsprovider.cpp b/src/lyrics/musixmatchlyricsprovider.cpp index 814299c21..e18811e4a 100644 --- a/src/lyrics/musixmatchlyricsprovider.cpp +++ b/src/lyrics/musixmatchlyricsprovider.cpp @@ -80,7 +80,9 @@ bool MusixmatchLyricsProvider::StartSearch(const QString &artist, const QString #else req.setAttribute(QNetworkRequest::FollowRedirectsAttribute, true); #endif +#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0) req.setAttribute(QNetworkRequest::Http2AllowedAttribute, false); +#endif QNetworkReply *reply = network_->get(req); replies_ << reply; connect(reply, &QNetworkReply::finished, [=] { HandleSearchReply(reply, id, artist, album, title); });