From c415b6afa6fcd98f5c5fe3e57b1c5dd381356550 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Thu, 28 Mar 2013 18:47:54 -0400 Subject: [PATCH] removed duplicate resource pool --- .../Providers/Movies/FanArtMovieProvider.cs | 5 ----- MediaBrowser.Controller/Providers/TV/FanArtTVProvider.cs | 8 ++++---- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/MediaBrowser.Controller/Providers/Movies/FanArtMovieProvider.cs b/MediaBrowser.Controller/Providers/Movies/FanArtMovieProvider.cs index af613f023..7079f3330 100644 --- a/MediaBrowser.Controller/Providers/Movies/FanArtMovieProvider.cs +++ b/MediaBrowser.Controller/Providers/Movies/FanArtMovieProvider.cs @@ -19,11 +19,6 @@ namespace MediaBrowser.Controller.Providers.Movies /// class FanArtMovieProvider : FanartBaseProvider, IDisposable { - /// - /// The fan art - /// - internal readonly SemaphoreSlim FanArtResourcePool = new SemaphoreSlim(5, 5); - internal static FanArtMovieProvider Current { get; private set; } /// diff --git a/MediaBrowser.Controller/Providers/TV/FanArtTVProvider.cs b/MediaBrowser.Controller/Providers/TV/FanArtTVProvider.cs index 5690ba47f..982997ad3 100644 --- a/MediaBrowser.Controller/Providers/TV/FanArtTVProvider.cs +++ b/MediaBrowser.Controller/Providers/TV/FanArtTVProvider.cs @@ -69,7 +69,7 @@ namespace MediaBrowser.Controller.Providers.TV try { - using (var xml = await HttpClient.Get(url, FanArtMovieProvider.Current.FanArtResourcePool, cancellationToken).ConfigureAwait(false)) + using (var xml = await HttpClient.Get(url, FanArtResourcePool, cancellationToken).ConfigureAwait(false)) { doc.Load(xml); } @@ -93,7 +93,7 @@ namespace MediaBrowser.Controller.Providers.TV Logger.Debug("FanArtProvider getting ClearLogo for " + series.Name); try { - series.SetImage(ImageType.Logo, await _providerManager.DownloadAndSaveImage(series, path, LOGO_FILE, FanArtMovieProvider.Current.FanArtResourcePool, cancellationToken).ConfigureAwait(false)); + series.SetImage(ImageType.Logo, await _providerManager.DownloadAndSaveImage(series, path, LOGO_FILE, FanArtResourcePool, cancellationToken).ConfigureAwait(false)); } catch (HttpException) { @@ -117,7 +117,7 @@ namespace MediaBrowser.Controller.Providers.TV Logger.Debug("FanArtProvider getting ClearArt for " + series.Name); try { - series.SetImage(ImageType.Art, await _providerManager.DownloadAndSaveImage(series, path, ART_FILE, FanArtMovieProvider.Current.FanArtResourcePool, cancellationToken).ConfigureAwait(false)); + series.SetImage(ImageType.Art, await _providerManager.DownloadAndSaveImage(series, path, ART_FILE, FanArtResourcePool, cancellationToken).ConfigureAwait(false)); } catch (HttpException) { @@ -141,7 +141,7 @@ namespace MediaBrowser.Controller.Providers.TV Logger.Debug("FanArtProvider getting ThumbArt for " + series.Name); try { - series.SetImage(ImageType.Disc, await _providerManager.DownloadAndSaveImage(series, path, THUMB_FILE, FanArtMovieProvider.Current.FanArtResourcePool, cancellationToken).ConfigureAwait(false)); + series.SetImage(ImageType.Disc, await _providerManager.DownloadAndSaveImage(series, path, THUMB_FILE, FanArtResourcePool, cancellationToken).ConfigureAwait(false)); } catch (HttpException) {