From 3137cc4657e3688968ec323e452cbcc56de76956 Mon Sep 17 00:00:00 2001 From: Josh Patra Date: Sat, 31 Jan 2026 18:07:22 -0500 Subject: [PATCH] fix: remove duplicate Spotify playlist interception code with compilation error --- allstarr/Controllers/JellyfinController.cs | 27 ---------------------- 1 file changed, 27 deletions(-) diff --git a/allstarr/Controllers/JellyfinController.cs b/allstarr/Controllers/JellyfinController.cs index fa71b70..8d33364 100644 --- a/allstarr/Controllers/JellyfinController.cs +++ b/allstarr/Controllers/JellyfinController.cs @@ -1685,33 +1685,6 @@ public class JellyfinController : ControllerBase } } } - { - // Extract playlist ID from path: playlists/{id}/items - var parts = path.Split('/'); - if (parts.Length == 3) - { - var playlistId = parts[1]; - _logger.LogInformation("=== SPOTIFY INTERCEPTION === Checking playlist {PlaylistId}", playlistId); - - // Get playlist info from Jellyfin to check the name - var playlistInfo = await _proxyService.GetJsonAsync($"Items/{playlistId}", null, Request.Headers); - if (playlistInfo != null && playlistInfo.RootElement.TryGetProperty("Name", out var nameElement)) - { - var playlistName = nameElement.GetString() ?? ""; - _logger.LogInformation("Playlist name: {PlaylistName}", playlistName); - - // Check if this matches any configured Spotify playlists - var matchingConfig = _spotifySettings.Playlists - .FirstOrDefault(p => p.Enabled && p.Name.Equals(playlistName, StringComparison.OrdinalIgnoreCase)); - - if (matchingConfig != null) - { - _logger.LogInformation("=== INTERCEPTING SPOTIFY PLAYLIST === {PlaylistName}", playlistName); - return await GetSpotifyPlaylistTracksAsync(matchingConfig.SpotifyName); - } - } - } - } // Handle non-JSON responses (robots.txt, etc.) if (path.EndsWith(".txt", StringComparison.OrdinalIgnoreCase) ||