From e8471bcc6672f34faba3761ebd873623b9f9e77e Mon Sep 17 00:00:00 2001 From: Jonas Kvinge Date: Sat, 24 Aug 2024 17:27:05 +0200 Subject: [PATCH] MusixmatchCoverProvider: Use static QRegularExpression --- src/covermanager/musixmatchcoverprovider.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/covermanager/musixmatchcoverprovider.cpp b/src/covermanager/musixmatchcoverprovider.cpp index 998b631f1..b870cdbe2 100644 --- a/src/covermanager/musixmatchcoverprovider.cpp +++ b/src/covermanager/musixmatchcoverprovider.cpp @@ -128,7 +128,8 @@ void MusixmatchCoverProvider::HandleSearchReply(QNetworkReply *reply, const int return; } - if (content_json.contains(QRegularExpression(QStringLiteral("<[^>]*>")))) { // Make sure it's not HTML code. + static const QRegularExpression regex_html_tag(QStringLiteral("<[^>]*>")); + if (content_json.contains(regex_html_tag)) { // Make sure it's not HTML code. emit SearchFinished(id, results); return; }