From 499b2225146164987a5c3724d329512f89be83e9 Mon Sep 17 00:00:00 2001 From: Qstick Date: Wed, 31 Jan 2018 21:31:37 -0500 Subject: [PATCH] Fixed: Plex TV Library updates instead of Music closes #148 --- src/NzbDrone.Core/Notifications/Plex/PlexServerProxy.cs | 8 ++++---- src/NzbDrone.Core/Notifications/Plex/PlexServerService.cs | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/NzbDrone.Core/Notifications/Plex/PlexServerProxy.cs b/src/NzbDrone.Core/Notifications/Plex/PlexServerProxy.cs index f47771395..402e68866 100644 --- a/src/NzbDrone.Core/Notifications/Plex/PlexServerProxy.cs +++ b/src/NzbDrone.Core/Notifications/Plex/PlexServerProxy.cs @@ -16,7 +16,7 @@ namespace NzbDrone.Core.Notifications.Plex { public interface IPlexServerProxy { - List GetTvSections(PlexServerSettings settings); + List GetArtistSections(PlexServerSettings settings); void Update(int sectionId, PlexServerSettings settings); void UpdateSeries(int metadataId, PlexServerSettings settings); string Version(PlexServerSettings settings); @@ -35,7 +35,7 @@ namespace NzbDrone.Core.Notifications.Plex _logger = logger; } - public List GetTvSections(PlexServerSettings settings) + public List GetArtistSections(PlexServerSettings settings) { var request = GetPlexServerRequest("library/sections", Method.GET, settings); var client = GetPlexServerClient(settings); @@ -48,7 +48,7 @@ namespace NzbDrone.Core.Notifications.Plex { return Json.Deserialize(response.Content) .Sections - .Where(d => d.Type == "show") + .Where(d => d.Type == "artist") .Select(s => new PlexSection { Id = s.Id, @@ -62,7 +62,7 @@ namespace NzbDrone.Core.Notifications.Plex return Json.Deserialize>(response.Content) .MediaContainer .Sections - .Where(d => d.Type == "show") + .Where(d => d.Type == "artist") .ToList(); } diff --git a/src/NzbDrone.Core/Notifications/Plex/PlexServerService.cs b/src/NzbDrone.Core/Notifications/Plex/PlexServerService.cs index b5d71416a..aeeb85905 100644 --- a/src/NzbDrone.Core/Notifications/Plex/PlexServerService.cs +++ b/src/NzbDrone.Core/Notifications/Plex/PlexServerService.cs @@ -66,7 +66,7 @@ namespace NzbDrone.Core.Notifications.Plex { _logger.Debug("Getting sections from Plex host: {0}", settings.Host); - return _plexServerProxy.GetTvSections(settings).ToList(); + return _plexServerProxy.GetArtistSections(settings).ToList(); } private bool PartialUpdatesAllowed(PlexServerSettings settings, Version version)