From efeaa59512508b668fe568fcab583c9ea7457e91 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Wed, 16 Oct 2013 16:49:44 -0400 Subject: [PATCH] fixed last fm image provider downloading images over and over --- MediaBrowser.Providers/Music/LastFmImageProvider.cs | 2 +- MediaBrowser.Providers/Music/LastfmArtistProvider.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/MediaBrowser.Providers/Music/LastFmImageProvider.cs b/MediaBrowser.Providers/Music/LastFmImageProvider.cs index 9ebad8b38..5078326af 100644 --- a/MediaBrowser.Providers/Music/LastFmImageProvider.cs +++ b/MediaBrowser.Providers/Music/LastFmImageProvider.cs @@ -74,7 +74,7 @@ namespace MediaBrowser.Providers.Music { var url = GetImageUrl(item); - if (!string.IsNullOrWhiteSpace(url)) + if (!string.IsNullOrWhiteSpace(url) && !item.HasImage(ImageType.Primary)) { await _providerManager.SaveImage(item, url, LastfmBaseProvider.LastfmResourcePool, ImageType.Primary, null, cancellationToken) .ConfigureAwait(false); diff --git a/MediaBrowser.Providers/Music/LastfmArtistProvider.cs b/MediaBrowser.Providers/Music/LastfmArtistProvider.cs index 7d1cb715f..b59b84117 100644 --- a/MediaBrowser.Providers/Music/LastfmArtistProvider.cs +++ b/MediaBrowser.Providers/Music/LastfmArtistProvider.cs @@ -75,7 +75,7 @@ namespace MediaBrowser.Providers.Music { return item.LocationType == LocationType.FileSystem && item.ResolveArgs.ContainsMetaFileByName("artist.xml"); } - + /// /// Finds the id. ///