mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-07-09 03:04:24 -04:00
Don't manually dispose DeviceDiscovery
The lifetime of DeviceDiscovery is managed by DI
This commit is contained in:
parent
2e1b8ea62d
commit
5b51645381
@ -188,19 +188,6 @@ namespace Emby.Dlna.Main
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void DisposeDeviceDiscovery()
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
_logger.LogInformation("Disposing DeviceDiscovery");
|
|
||||||
((DeviceDiscovery)_deviceDiscovery).Dispose();
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
_logger.LogError(ex, "Error stopping device discovery");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void StartDevicePublisher(Configuration.DlnaOptions options)
|
public void StartDevicePublisher(Configuration.DlnaOptions options)
|
||||||
{
|
{
|
||||||
if (_publisher is not null)
|
if (_publisher is not null)
|
||||||
@ -399,7 +386,6 @@ namespace Emby.Dlna.Main
|
|||||||
|
|
||||||
DisposeDevicePublisher();
|
DisposeDevicePublisher();
|
||||||
DisposePlayToManager();
|
DisposePlayToManager();
|
||||||
DisposeDeviceDiscovery();
|
|
||||||
|
|
||||||
if (_communicationsServer is not null)
|
if (_communicationsServer is not null)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user