This commit is contained in:
Bond_009 2019-01-26 18:27:57 +01:00
parent 07f163a4c3
commit 2ffab720fb
2 changed files with 5 additions and 9 deletions

View File

@ -317,7 +317,7 @@ namespace Emby.Server.Implementations
private IUserDataManager UserDataManager { get; set; }
private IUserRepository UserRepository { get; set; }
internal IDisplayPreferencesRepository DisplayPreferencesRepository { get; set; }
internal IItemRepository ItemRepository { get; set; }
internal SqliteItemRepository ItemRepository { get; set; }
private INotificationManager NotificationManager { get; set; }
private ISubtitleManager SubtitleManager { get; set; }
@ -836,9 +836,8 @@ namespace Emby.Server.Implementations
DisplayPreferencesRepository = displayPreferencesRepo;
RegisterSingleInstance(DisplayPreferencesRepository);
var itemRepo = new SqliteItemRepository(ServerConfigurationManager, this, JsonSerializer, LoggerFactory, assemblyInfo, FileSystemManager, EnvironmentInfo, TimerFactory);
ItemRepository = itemRepo;
RegisterSingleInstance(ItemRepository);
ItemRepository = new SqliteItemRepository(ServerConfigurationManager, this, JsonSerializer, LoggerFactory, assemblyInfo);
RegisterSingleInstance<IItemRepository>(ItemRepository);
AuthenticationRepository = GetAuthenticationRepository();
RegisterSingleInstance(AuthenticationRepository);
@ -956,7 +955,7 @@ namespace Emby.Server.Implementations
((UserManager)UserManager).Initialize();
((UserDataManager)UserDataManager).Repository = userDataRepo;
itemRepo.Initialize(userDataRepo, UserManager);
ItemRepository.Initialize(userDataRepo, UserManager);
((LibraryManager)LibraryManager).ItemRepository = ItemRepository;
}

View File

@ -69,10 +69,7 @@ namespace Emby.Server.Implementations.Data
IServerApplicationHost appHost,
IJsonSerializer jsonSerializer,
ILoggerFactory loggerFactory,
IAssemblyInfo assemblyInfo,
IFileSystem fileSystem,
IEnvironmentInfo environmentInfo,
ITimerFactory timerFactory)
IAssemblyInfo assemblyInfo)
: base(loggerFactory.CreateLogger(nameof(SqliteItemRepository)))
{
if (config == null)