aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/Library/LibraryService.cs
diff options
context:
space:
mode:
authorBond_009 <Bond.009@outlook.com>2020-05-27 20:49:18 +0200
committerBond_009 <Bond.009@outlook.com>2020-05-27 20:49:18 +0200
commit7439e095e276034f05a0c9e9c7687b4a0aa1b3e5 (patch)
treec1c0a8f64157cac9117e3a885f7308802a5a98d8 /MediaBrowser.Api/Library/LibraryService.cs
parent27ce10d0c13bc30fa1b08682e13bab67784b289d (diff)
parent777c9c7bc974fafb09e6a5a6b23bd29cf8529af9 (diff)
Merge branch 'master' into nullable3
Diffstat (limited to 'MediaBrowser.Api/Library/LibraryService.cs')
-rw-r--r--MediaBrowser.Api/Library/LibraryService.cs15
1 files changed, 9 insertions, 6 deletions
diff --git a/MediaBrowser.Api/Library/LibraryService.cs b/MediaBrowser.Api/Library/LibraryService.cs
index a54640b2f..c0146dfee 100644
--- a/MediaBrowser.Api/Library/LibraryService.cs
+++ b/MediaBrowser.Api/Library/LibraryService.cs
@@ -319,11 +319,14 @@ namespace MediaBrowser.Api.Library
private readonly ILocalizationManager _localization;
private readonly ILibraryMonitor _libraryMonitor;
+ private readonly ILogger<MoviesService> _moviesServiceLogger;
+
/// <summary>
/// Initializes a new instance of the <see cref="LibraryService" /> class.
/// </summary>
public LibraryService(
ILogger<LibraryService> logger,
+ ILogger<MoviesService> moviesServiceLogger,
IServerConfigurationManager serverConfigurationManager,
IHttpResultFactory httpResultFactory,
IProviderManager providerManager,
@@ -344,6 +347,7 @@ namespace MediaBrowser.Api.Library
_activityManager = activityManager;
_localization = localization;
_libraryMonitor = libraryMonitor;
+ _moviesServiceLogger = moviesServiceLogger;
}
private string[] GetRepresentativeItemTypes(string contentType)
@@ -543,7 +547,7 @@ namespace MediaBrowser.Api.Library
if (item is Movie || (program != null && program.IsMovie) || item is Trailer)
{
return new MoviesService(
- Logger,
+ _moviesServiceLogger,
ServerConfigurationManager,
ResultFactory,
_userManager,
@@ -759,13 +763,12 @@ namespace MediaBrowser.Api.Library
{
try
{
- _activityManager.Create(new ActivityLogEntry
+ _activityManager.Create(new Jellyfin.Data.Entities.ActivityLog(
+ string.Format(_localization.GetLocalizedString("UserDownloadingItemWithValues"), user.Name, item.Name),
+ "UserDownloadingContent",
+ auth.UserId)
{
- Name = string.Format(_localization.GetLocalizedString("UserDownloadingItemWithValues"), user.Name, item.Name),
- Type = "UserDownloadingContent",
ShortOverview = string.Format(_localization.GetLocalizedString("AppDeviceValues"), auth.Client, auth.Device),
- UserId = auth.UserId
-
});
}
catch