From 26b6d9acb6c769a5c8c27ed656604fb7576d8c16 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=E2=96=88=E2=96=88=E2=96=88=E2=96=88=E2=96=88?= Date: Mon, 28 Apr 2025 16:42:41 -0400 Subject: [PATCH] feat: fix invalid cast exception --- EFCore/src/Migrations/Internal/MySQLHistoryRepository.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/EFCore/src/Migrations/Internal/MySQLHistoryRepository.cs b/EFCore/src/Migrations/Internal/MySQLHistoryRepository.cs index 7c7e982a8..8a54f4791 100644 --- a/EFCore/src/Migrations/Internal/MySQLHistoryRepository.cs +++ b/EFCore/src/Migrations/Internal/MySQLHistoryRepository.cs @@ -95,10 +95,10 @@ public override async Task AcquireDatabaseLockAsync(Can Dependencies.MigrationsLogger.AcquiringMigrationLock(); var dbLock = CreateMigrationDatabaseLock(); - int result; + Int64 result; try { - result = (int)(await CreateGetLockCommand().ExecuteScalarAsync(CreateRelationalCommandParameters(), cancellationToken) + result = (Int64)(await CreateGetLockCommand().ExecuteScalarAsync(CreateRelationalCommandParameters(), cancellationToken) .ConfigureAwait(false))!; } catch