Skip to content

Commit

Permalink
Don't store media encoder as field
Browse files Browse the repository at this point in the history
  • Loading branch information
barronpm committed Jan 28, 2023
1 parent f7ec85d commit 0bbeead
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions Emby.Server.Implementations/ApplicationHost.cs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,6 @@ public abstract class ApplicationHost : IServerApplicationHost, IAsyncDisposable
private readonly IPluginManager _pluginManager;

private List<Type> _creatingInstances;
private IMediaEncoder _mediaEncoder;
private ISessionManager _sessionManager;

/// <summary>
Expand Down Expand Up @@ -419,7 +418,7 @@ public async Task RunStartupTasksAsync(CancellationToken cancellationToken)
ConfigurationManager.ConfigurationUpdated += OnConfigurationUpdated;
ConfigurationManager.NamedConfigurationUpdated += OnConfigurationUpdated;

_mediaEncoder.SetFFmpegPath();
Resolve<IMediaEncoder>().SetFFmpegPath();

Logger.LogInformation("ServerId: {ServerId}", SystemId);

Expand Down Expand Up @@ -631,7 +630,6 @@ await using (jellyfinDb.ConfigureAwait(false))
var localizationManager = (LocalizationManager)Resolve<ILocalizationManager>();
await localizationManager.LoadAll().ConfigureAwait(false);

_mediaEncoder = Resolve<IMediaEncoder>();
_sessionManager = Resolve<ISessionManager>();

SetStaticProperties();
Expand Down

0 comments on commit 0bbeead

Please sign in to comment.