diff options
| author | BaronGreenback <jimcartlidge@yahoo.co.uk> | 2020-06-15 10:01:55 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-06-15 10:01:55 +0100 |
| commit | 862bcdba67d3b992fc7e68a7428fc225c898fce3 (patch) | |
| tree | 10a66c6cc918962cd2dad54fe85c65016af9cf9d /Jellyfin.Server/CoreAppHost.cs | |
| parent | 4d50941d4458dc93880d99192fd1c26a8f625d66 (diff) | |
| parent | 100e9d586dff877610c488936aa035f61f6fedb5 (diff) | |
Merge pull request #23 from jellyfin/master
updating
Diffstat (limited to 'Jellyfin.Server/CoreAppHost.cs')
| -rw-r--r-- | Jellyfin.Server/CoreAppHost.cs | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/Jellyfin.Server/CoreAppHost.cs b/Jellyfin.Server/CoreAppHost.cs index 331a32c73..fe07411a6 100644 --- a/Jellyfin.Server/CoreAppHost.cs +++ b/Jellyfin.Server/CoreAppHost.cs @@ -7,8 +7,10 @@ using Emby.Server.Implementations; using Jellyfin.Drawing.Skia; using Jellyfin.Server.Implementations; using Jellyfin.Server.Implementations.Activity; +using Jellyfin.Server.Implementations.Users; using MediaBrowser.Common.Net; using MediaBrowser.Controller.Drawing; +using MediaBrowser.Controller.Library; using MediaBrowser.Model.Activity; using MediaBrowser.Model.IO; using Microsoft.EntityFrameworkCore; @@ -63,12 +65,15 @@ namespace Jellyfin.Server // TODO: Set up scoping and use AddDbContextPool serviceCollection.AddDbContext<JellyfinDb>( - options => options.UseSqlite($"Filename={Path.Combine(ApplicationPaths.DataPath, "jellyfin.db")}"), - ServiceLifetime.Transient); + options => options + .UseSqlite($"Filename={Path.Combine(ApplicationPaths.DataPath, "jellyfin.db")}") + .UseLazyLoadingProxies(), + ServiceLifetime.Transient); serviceCollection.AddSingleton<JellyfinDbProvider>(); serviceCollection.AddSingleton<IActivityManager, ActivityManager>(); + serviceCollection.AddSingleton<IUserManager, UserManager>(); base.RegisterServices(serviceCollection); } @@ -79,7 +84,11 @@ namespace Jellyfin.Server /// <inheritdoc /> protected override IEnumerable<Assembly> GetAssembliesWithPartsInternal() { + // Jellyfin.Server yield return typeof(CoreAppHost).Assembly; + + // Jellyfin.Server.Implementations + yield return typeof(JellyfinDb).Assembly; } /// <inheritdoc /> |
