Close bookmarks db connection before trying to delete the file

This commit is contained in:
Yusyuriv 2025-03-20 14:47:50 +06:00
parent 92ef2c76c7
commit a837e8e197
No known key found for this signature in database
GPG key ID: A91C52E6F73148E0
2 changed files with 3 additions and 0 deletions

View file

@ -195,6 +195,7 @@ public abstract class ChromiumBookmarkLoader : IBookmarkLoader
// https://github.com/dotnet/efcore/issues/26580
SqliteConnection.ClearPool(connection);
connection.Close();
}
catch (Exception ex)
{

View file

@ -85,6 +85,7 @@ public abstract class FirefoxBookmarkLoaderBase : IBookmarkLoader
// https://github.com/dotnet/efcore/issues/26580
SqliteConnection.ClearPool(dbConnection);
dbConnection.Close();
// Delete temporary file
try
@ -171,6 +172,7 @@ public abstract class FirefoxBookmarkLoaderBase : IBookmarkLoader
// https://github.com/dotnet/efcore/issues/26580
SqliteConnection.ClearPool(connection);
connection.Close();
// Delete temporary file
try