aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Dto/DtoService.cs
diff options
context:
space:
mode:
authorCody Robibero <cody@robibe.ro>2024-02-21 14:24:50 -0700
committerGitHub <noreply@github.com>2024-02-21 14:24:50 -0700
commitca21a80c95d7e96734484ee642f761be2f3a4d0c (patch)
tree1ab2e7e37295492788e5edd572a67e503862061f /Emby.Server.Implementations/Dto/DtoService.cs
parent1dfaa171a95e3e6eea780f018cd8442f1dcc9f78 (diff)
parent170b8b2550a6ebb08453fe96d6c2223eaa1aa0ff (diff)
Merge pull request #11045 from barronpm/livetv-recordingsmanager
LiveTV Recordings Refactor
Diffstat (limited to 'Emby.Server.Implementations/Dto/DtoService.cs')
-rw-r--r--Emby.Server.Implementations/Dto/DtoService.cs8
1 files changed, 5 insertions, 3 deletions
diff --git a/Emby.Server.Implementations/Dto/DtoService.cs b/Emby.Server.Implementations/Dto/DtoService.cs
index d0d5bb81c..d372277e0 100644
--- a/Emby.Server.Implementations/Dto/DtoService.cs
+++ b/Emby.Server.Implementations/Dto/DtoService.cs
@@ -47,6 +47,7 @@ namespace Emby.Server.Implementations.Dto
private readonly IImageProcessor _imageProcessor;
private readonly IProviderManager _providerManager;
+ private readonly IRecordingsManager _recordingsManager;
private readonly IApplicationHost _appHost;
private readonly IMediaSourceManager _mediaSourceManager;
@@ -62,6 +63,7 @@ namespace Emby.Server.Implementations.Dto
IItemRepository itemRepo,
IImageProcessor imageProcessor,
IProviderManager providerManager,
+ IRecordingsManager recordingsManager,
IApplicationHost appHost,
IMediaSourceManager mediaSourceManager,
Lazy<ILiveTvManager> livetvManagerFactory,
@@ -74,6 +76,7 @@ namespace Emby.Server.Implementations.Dto
_itemRepo = itemRepo;
_imageProcessor = imageProcessor;
_providerManager = providerManager;
+ _recordingsManager = recordingsManager;
_appHost = appHost;
_mediaSourceManager = mediaSourceManager;
_livetvManagerFactory = livetvManagerFactory;
@@ -256,8 +259,7 @@ namespace Emby.Server.Implementations.Dto
dto.Etag = item.GetEtag(user);
}
- var liveTvManager = LivetvManager;
- var activeRecording = liveTvManager.GetActiveRecordingInfo(item.Path);
+ var activeRecording = _recordingsManager.GetActiveRecordingInfo(item.Path);
if (activeRecording is not null)
{
dto.Type = BaseItemKind.Recording;
@@ -270,7 +272,7 @@ namespace Emby.Server.Implementations.Dto
dto.Name = dto.SeriesName;
}
- liveTvManager.AddInfoToRecordingDto(item, dto, activeRecording, user);
+ LivetvManager.AddInfoToRecordingDto(item, dto, activeRecording, user);
}
return dto;