The Free Software Media System - Server Backend & API
Fix NullReferenceException at startup
ferferga28f07df65730
diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/ChapterImagesTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/ChapterImagesTask.csindex 81149ba2e6..36677dbeca 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/ChapterImagesTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/ChapterImagesTask.cs@@ -45,7 +45,14 @@ namespace Emby.Server.Implementations.ScheduledTasks/// <summary>/// Initializes a new instance of the <see cref="ChapterImagesTask" /> class./// </summary>- public ChapterImagesTask(ILoggerFactory loggerFactory, ILibraryManager libraryManager, IItemRepository itemRepo, IApplicationPaths appPaths, IEncodingManager encodingManager, IFileSystem fileSystem)+ public ChapterImagesTask(+ ILoggerFactory loggerFactory,+ ILibraryManager libraryManager,+ IItemRepository itemRepo,+ IApplicationPaths appPaths,+ IEncodingManager encodingManager,+ IFileSystem fileSystem,+ ILocalizationManager localization){_logger = loggerFactory.CreateLogger(GetType().Name);_libraryManager = libraryManager;@@ -53,6 +60,7 @@ namespace Emby.Server.Implementations.ScheduledTasks_appPaths = appPaths;_encodingManager = encodingManager;_fileSystem = fileSystem;+ _localization = localization;}/// <summary>diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteCacheFileTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteCacheFileTask.csindex e7e174fb1a..d24c8224e3 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteCacheFileTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteCacheFileTask.cs@@ -34,11 +34,13 @@ namespace Emby.Server.Implementations.ScheduledTasks.Taskspublic DeleteCacheFileTask(IApplicationPaths appPaths,ILogger<DeleteCacheFileTask> logger,- IFileSystem fileSystem)+ IFileSystem fileSystem,+ ILocalizationManager localization){ApplicationPaths = appPaths;_logger = logger;_fileSystem = fileSystem;+ _localization = localization;}/// <summary>diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteLogFileTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteLogFileTask.csindex 1c3cefbce4..30065cee78 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteLogFileTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteLogFileTask.cs@@ -28,10 +28,11 @@ namespace Emby.Server.Implementations.ScheduledTasks.Tasks/// Initializes a new instance of the <see cref="DeleteLogFileTask" /> class./// </summary>/// <param name="configurationManager">The configuration manager.</param>- public DeleteLogFileTask(IConfigurationManager configurationManager, IFileSystem fileSystem)+ public DeleteLogFileTask(IConfigurationManager configurationManager, IFileSystem fileSystem, ILocalizationManager localization){ConfigurationManager = configurationManager;_fileSystem = fileSystem;+ _localization = localization;}/// <summary>diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteTranscodeFileTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteTranscodeFileTask.csindex e4b3de8224..572158a139 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteTranscodeFileTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/DeleteTranscodeFileTask.cs@@ -28,11 +28,13 @@ namespace Emby.Server.Implementations.ScheduledTasks.Taskspublic DeleteTranscodeFileTask(ILogger<DeleteTranscodeFileTask> logger,IFileSystem fileSystem,- IConfigurationManager configurationManager)+ IConfigurationManager configurationManager,+ ILocalizationManager localization){_logger = logger;_fileSystem = fileSystem;_configurationManager = configurationManager;+ _localization = localization;}/// <summary>diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/PeopleValidationTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/PeopleValidationTask.csindex 90a8f7c1b8..49c21f523d 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/PeopleValidationTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/PeopleValidationTask.cs@@ -27,10 +27,11 @@ namespace Emby.Server.Implementations.ScheduledTasks/// </summary>/// <param name="libraryManager">The library manager.</param>/// <param name="appHost">The server application host</param>- public PeopleValidationTask(ILibraryManager libraryManager, IServerApplicationHost appHost)+ public PeopleValidationTask(ILibraryManager libraryManager, IServerApplicationHost appHost, ILocalizationManager localization){_libraryManager = libraryManager;_appHost = appHost;+ _localization = localization;}/// <summary>diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/PluginUpdateTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/PluginUpdateTask.csindex 0a26cbf6d9..a82588a0e1 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/PluginUpdateTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/PluginUpdateTask.cs@@ -25,10 +25,11 @@ namespace Emby.Server.Implementations.ScheduledTasksprivate readonly IInstallationManager _installationManager;private readonly ILocalizationManager _localization;- public PluginUpdateTask(ILogger<PluginUpdateTask> logger, IInstallationManager installationManager)+ public PluginUpdateTask(ILogger<PluginUpdateTask> logger, IInstallationManager installationManager, ILocalizationManager localization){_logger = logger;_installationManager = installationManager;+ _localization = localization;}/// <summary>diff --git a/Emby.Server.Implementations/ScheduledTasks/Tasks/RefreshMediaLibraryTask.cs b/Emby.Server.Implementations/ScheduledTasks/Tasks/RefreshMediaLibraryTask.csindex 08b51a72fc..da534e9a74 100644--- a/Emby.Server.Implementations/ScheduledTasks/Tasks/RefreshMediaLibraryTask.cs+++ b/Emby.Server.Implementations/ScheduledTasks/Tasks/RefreshMediaLibraryTask.cs@@ -26,10 +26,11 @@ namespace Emby.Server.Implementations.ScheduledTasks/// Initializes a new instance of the <see cref="RefreshMediaLibraryTask" /> class./// </summary>/// <param name="libraryManager">The library manager.</param>- public RefreshMediaLibraryTask(ILibraryManager libraryManager, IServerConfigurationManager config)+ public RefreshMediaLibraryTask(ILibraryManager libraryManager, IServerConfigurationManager config, ILocalizationManager localization){_libraryManager = libraryManager;_config = config;+ _localization = localization;}/// <summary>