Increase lyrics score if lyrics text > 60

This commit is contained in:
Jonas Kvinge
2020-01-02 19:21:27 +01:00
parent 7f442cff3b
commit 443be1c2c8
6 changed files with 13 additions and 0 deletions

View File

@@ -87,6 +87,9 @@ void OVHLyricsProvider::HandleSearchReply(QNetworkReply *reply, const quint64 id
LyricsSearchResult result;
result.lyrics = json_obj["lyrics"].toString();
if (result.lyrics.length() > LyricsFetcher::kGoodLyricsLength)
result.score += 1.0;
qLog(Debug) << "OVHLyrics: Got lyrics for" << artist << title;
emit SearchFinished(id, LyricsSearchResults() << result);