From 66716a9bc965ac2fba5575ba3dc53e25889424a1 Mon Sep 17 00:00:00 2001 From: Thomas Gander Date: Sun, 25 Jan 2026 09:15:26 -0700 Subject: [PATCH] Updated logging to be more concise when debug is not active --- .../ScheduledTasks/StaleMediaTask.cs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Jellyfin.Plugin.MediaCleaner/ScheduledTasks/StaleMediaTask.cs b/Jellyfin.Plugin.MediaCleaner/ScheduledTasks/StaleMediaTask.cs index d7dfb28..13a8c9d 100644 --- a/Jellyfin.Plugin.MediaCleaner/ScheduledTasks/StaleMediaTask.cs +++ b/Jellyfin.Plugin.MediaCleaner/ScheduledTasks/StaleMediaTask.cs @@ -73,27 +73,27 @@ public sealed class StaleMediaTask : IScheduledTask List allItems = [.. _libraryManager.GetItemsResult(query).Items]; - _loggingHelper.LogInformation("Total items: {ItemCount}", allItems.Count); + _loggingHelper.LogInformation("Total items to scan: {ItemCount}", allItems.Count); _loggingHelper.LogDebugInformation("Items found: {AllItems}", allItems); List series = [.. allItems.Where(item => item.GetBaseItemKind() == BaseItemKind.Series)]; List movies = [.. allItems.Where(item => item.GetBaseItemKind() == BaseItemKind.Movie)]; - _loggingHelper.LogInformation("-------------------------------------------------"); - _loggingHelper.LogInformation("Starting scan of series items."); + _loggingHelper.LogDebugInformation("-------------------------------------------------"); + _loggingHelper.LogDebugInformation("Starting scan of series items."); List staleSeasons = [.. series.SelectMany(GetStaleSeasons)]; - _loggingHelper.LogInformation("-------------------------------------------------"); - _loggingHelper.LogInformation("End of scan for series items."); + _loggingHelper.LogDebugInformation("-------------------------------------------------"); + _loggingHelper.LogDebugInformation("End of scan for series items."); - _loggingHelper.LogInformation("-------------------------------------------------"); - _loggingHelper.LogInformation("Starting scan of movie items."); + _loggingHelper.LogDebugInformation("-------------------------------------------------"); + _loggingHelper.LogDebugInformation("Starting scan of movie items."); List staleMovies = [.. GetStaleMovies(movies)]; - _loggingHelper.LogInformation("-------------------------------------------------"); - _loggingHelper.LogInformation("End of scan for movie items."); + _loggingHelper.LogDebugInformation("-------------------------------------------------"); + _loggingHelper.LogDebugInformation("End of scan for movie items."); _loggingHelper.LogInformation("-------------------------------------------------"); _loggingHelper.LogInformation("Stale seasons found: {StaleSeasons}", staleSeasons.Count);