mirror of
https://github.com/ppy/osu.git
synced 2024-09-22 12:07:23 +08:00
Avoid closing initial context after migrations (unnecessary)
This commit is contained in:
parent
0dca9c8c46
commit
2e4c3c8e39
@ -38,11 +38,9 @@ namespace osu.Game.Database
|
|||||||
|
|
||||||
threadContexts = new ThreadLocal<Realm>(createContext, true);
|
threadContexts = new ThreadLocal<Realm>(createContext, true);
|
||||||
|
|
||||||
using (var realm = Get())
|
// creating a context will ensure our schema is up-to-date and migrated.
|
||||||
{
|
var realm = Get();
|
||||||
Logger.Log($"Opened realm {database_name} at version {realm.Config.SchemaVersion}");
|
Logger.Log($"Opened realm \"{realm.Config.DatabasePath}\" at version {realm.Config.SchemaVersion}");
|
||||||
// creating a context will ensure our schema is up-to-date and migrated.
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void onMigration(Migration migration, ulong lastSchemaVersion)
|
private void onMigration(Migration migration, ulong lastSchemaVersion)
|
||||||
|
Loading…
Reference in New Issue
Block a user