Inject logger correctly into ActivityManager and ActivityRepository
This commit is contained in:
parent
573da63d41
commit
7b31b0e322
|
@ -18,11 +18,11 @@ namespace Emby.Server.Implementations.Activity
|
||||||
private readonly IUserManager _userManager;
|
private readonly IUserManager _userManager;
|
||||||
|
|
||||||
public ActivityManager(
|
public ActivityManager(
|
||||||
ILoggerFactory loggerFactory,
|
ILogger<ActivityManager> logger,
|
||||||
IActivityRepository repo,
|
IActivityRepository repo,
|
||||||
IUserManager userManager)
|
IUserManager userManager)
|
||||||
{
|
{
|
||||||
_logger = loggerFactory.CreateLogger(nameof(ActivityManager));
|
_logger = logger;
|
||||||
_repo = repo;
|
_repo = repo;
|
||||||
_userManager = userManager;
|
_userManager = userManager;
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,8 +20,8 @@ namespace Emby.Server.Implementations.Activity
|
||||||
private static readonly CultureInfo _usCulture = CultureInfo.ReadOnly(new CultureInfo("en-US"));
|
private static readonly CultureInfo _usCulture = CultureInfo.ReadOnly(new CultureInfo("en-US"));
|
||||||
private readonly IFileSystem _fileSystem;
|
private readonly IFileSystem _fileSystem;
|
||||||
|
|
||||||
public ActivityRepository(ILoggerFactory loggerFactory, IServerApplicationPaths appPaths, IFileSystem fileSystem)
|
public ActivityRepository(ILogger<ActivityRepository> logger, IServerApplicationPaths appPaths, IFileSystem fileSystem)
|
||||||
: base(loggerFactory.CreateLogger(nameof(ActivityRepository)))
|
: base(logger)
|
||||||
{
|
{
|
||||||
DbFilePath = Path.Combine(appPaths.DataPath, "activitylog.db");
|
DbFilePath = Path.Combine(appPaths.DataPath, "activitylog.db");
|
||||||
_fileSystem = fileSystem;
|
_fileSystem = fileSystem;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user