mirror of
https://github.com/Sonarr/Sonarr.git
synced 2025-01-13 10:32:21 +02:00
Publish ApplicationStartingEvent during startup
This commit is contained in:
parent
237e7556c2
commit
5400bce129
@ -18,6 +18,8 @@
|
||||
using NzbDrone.Core.Configuration;
|
||||
using NzbDrone.Core.Datastore;
|
||||
using NzbDrone.Core.Instrumentation;
|
||||
using NzbDrone.Core.Lifecycle;
|
||||
using NzbDrone.Core.Messaging.Events;
|
||||
using NzbDrone.Host;
|
||||
using NzbDrone.Host.AccessControl;
|
||||
using NzbDrone.Http.Authentication;
|
||||
@ -202,6 +204,7 @@ public void Configure(IApplicationBuilder app,
|
||||
IConfigFileProvider configFileProvider,
|
||||
IRuntimeInfo runtimeInfo,
|
||||
IFirewallAdapter firewallAdapter,
|
||||
IEventAggregator eventAggregator,
|
||||
SonarrErrorPipeline errorHandler)
|
||||
{
|
||||
initializeLogger.Initialize();
|
||||
@ -223,6 +226,8 @@ public void Configure(IApplicationBuilder app,
|
||||
Console.CancelKeyPress += (sender, eventArgs) => NLog.LogManager.Configuration = null;
|
||||
}
|
||||
|
||||
eventAggregator.PublishEvent(new ApplicationStartingEvent());
|
||||
|
||||
if (OsInfo.IsWindows && runtimeInfo.IsAdmin)
|
||||
{
|
||||
firewallAdapter.MakeAccessible();
|
||||
|
Loading…
Reference in New Issue
Block a user