From 10fb96341cad47b87573fa9928f6c8a1c5d85691 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Nicol=C3=A1s=20Pina?= Date: Sat, 4 Jan 2014 16:55:41 +0100 Subject: [PATCH] Resolved empty song name when searching through Grooveshark. --- src/internet/groovesharkservice.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/internet/groovesharkservice.cpp b/src/internet/groovesharkservice.cpp index 65a77273f..af19640c4 100644 --- a/src/internet/groovesharkservice.cpp +++ b/src/internet/groovesharkservice.cpp @@ -1679,7 +1679,12 @@ Song GroovesharkService::ExtractSong(const QVariantMap& result_song) { Song song; if (!result_song.isEmpty()) { int song_id = result_song["SongID"].toInt(); - QString song_name = result_song["SongName"].toString(); + QString song_name; + if (result_song.contains("SongName")) { + song_name = result_song["SongName"].toString(); + } else { + song_name = result_song["Name"].toString(); + } int artist_id = result_song["ArtistID"].toInt(); QString artist_name = result_song["ArtistName"].toString(); int album_id = result_song["AlbumID"].toInt();