diff options
Diffstat (limited to 'Emby.Server.Implementations/ApplicationHost.cs')
| -rw-r--r-- | Emby.Server.Implementations/ApplicationHost.cs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/ApplicationHost.cs b/Emby.Server.Implementations/ApplicationHost.cs index 5bf9c4fc2..5292003f0 100644 --- a/Emby.Server.Implementations/ApplicationHost.cs +++ b/Emby.Server.Implementations/ApplicationHost.cs @@ -40,6 +40,7 @@ using Jellyfin.MediaEncoding.Hls.Playlist; using Jellyfin.Networking.Manager; using Jellyfin.Networking.Udp; using Jellyfin.Server.Implementations; +using Jellyfin.Server.Implementations.MediaSegments; using MediaBrowser.Common; using MediaBrowser.Common.Configuration; using MediaBrowser.Common.Events; @@ -401,7 +402,12 @@ namespace Emby.Server.Implementations ConfigurationManager.ConfigurationUpdated += OnConfigurationUpdated; ConfigurationManager.NamedConfigurationUpdated += OnConfigurationUpdated; - Resolve<IMediaEncoder>().SetFFmpegPath(); + var ffmpegValid = Resolve<IMediaEncoder>().SetFFmpegPath(); + + if (!ffmpegValid) + { + throw new FfmpegException("Failed to find valid ffmpeg"); + } Logger.LogInformation("ServerId: {ServerId}", SystemId); Logger.LogInformation("Core startup complete"); @@ -552,6 +558,8 @@ namespace Emby.Server.Implementations serviceCollection.AddScoped<DynamicHlsHelper>(); serviceCollection.AddScoped<IClientEventLogger, ClientEventLogger>(); serviceCollection.AddSingleton<IDirectoryService, DirectoryService>(); + + serviceCollection.AddSingleton<IMediaSegmentManager, MediaSegmentManager>(); } /// <summary> @@ -635,6 +643,7 @@ namespace Emby.Server.Implementations UserView.TVSeriesManager = Resolve<ITVSeriesManager>(); UserView.CollectionManager = Resolve<ICollectionManager>(); BaseItem.MediaSourceManager = Resolve<IMediaSourceManager>(); + BaseItem.MediaSegmentManager = Resolve<IMediaSegmentManager>(); CollectionFolder.XmlSerializer = _xmlSerializer; CollectionFolder.ApplicationHost = this; } |
