diff options
| author | Cody Robibero <cody@robibe.ro> | 2022-11-27 08:49:52 -0700 |
|---|---|---|
| committer | Cody Robibero <cody@robibe.ro> | 2022-11-27 08:49:52 -0700 |
| commit | 4e34c428d8ed8753af0fa81a8833ac92a7d2f5ac (patch) | |
| tree | 29fbe5f7355bc7dfe96a7787df34dec8fe75597d /Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs | |
| parent | 5787ab15dc297da6d2e1ec984ccf19751ed85db6 (diff) | |
| parent | d4bd72049b4609582fb57f63134bee58327bc0cc (diff) | |
Merge branch 'master' into fix-fmp4-flac-opus
Diffstat (limited to 'Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs')
| -rw-r--r-- | Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs b/Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs index ba0e33585..bf1ea8233 100644 --- a/Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs +++ b/Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs @@ -6,6 +6,7 @@ using Jellyfin.Data.Entities.Security; using Jellyfin.Server.Implementations; using MediaBrowser.Controller; using MediaBrowser.Controller.Library; +using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.Logging; using SQLitePCL.pretty; @@ -19,7 +20,7 @@ namespace Jellyfin.Server.Migrations.Routines private const string DbFilename = "authentication.db"; private readonly ILogger<MigrateAuthenticationDb> _logger; - private readonly JellyfinDbProvider _dbProvider; + private readonly IDbContextFactory<JellyfinDb> _dbProvider; private readonly IServerApplicationPaths _appPaths; private readonly IUserManager _userManager; @@ -32,7 +33,7 @@ namespace Jellyfin.Server.Migrations.Routines /// <param name="userManager">The user manager.</param> public MigrateAuthenticationDb( ILogger<MigrateAuthenticationDb> logger, - JellyfinDbProvider dbProvider, + IDbContextFactory<JellyfinDb> dbProvider, IServerApplicationPaths appPaths, IUserManager userManager) { @@ -60,7 +61,7 @@ namespace Jellyfin.Server.Migrations.Routines ConnectionFlags.ReadOnly, null)) { - using var dbContext = _dbProvider.CreateContext(); + using var dbContext = _dbProvider.CreateDbContext(); var authenticatedDevices = connection.Query("SELECT * FROM Tokens"); |
