aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs')
-rw-r--r--Jellyfin.Server/Migrations/Routines/MigrateAuthenticationDb.cs7
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");