From 563fdc5881aea347e21f8d4ad49dbb6915bde889 Mon Sep 17 00:00:00 2001 From: Hechtus Date: Sat, 22 Mar 2014 16:55:19 +0100 Subject: [PATCH] If not able to fetch the artist info return at least a default artist image. --- GoogleMusic/AllAccess.pm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/GoogleMusic/AllAccess.pm b/GoogleMusic/AllAccess.pm index f54f3ba..d9cb3f6 100644 --- a/GoogleMusic/AllAccess.pm +++ b/GoogleMusic/AllAccess.pm @@ -291,11 +291,10 @@ sub get_artist_image { }; if ($@) { $log->error("Not able to get the artist image for artist ID $id: $@"); - return; } my $image = '/html/images/artists.png'; - if (exists $googleArtist->{artistArtRef}) { + if ($googleArtist && exists $googleArtist->{artistArtRef}) { $image = $googleArtist->{artistArtRef}; $image = Plugins::GoogleMusic::Image->uri($image); }