Add back update thread verification in RealmContextFactory

This commit is contained in:
Dean Herbert
2021-10-11 15:20:12 +09:00
parent b946011292
commit f43badabf4

View File

@ -135,9 +135,8 @@ namespace osu.Game.Database
if (IsDisposed) if (IsDisposed)
throw new ObjectDisposedException(nameof(RealmContextFactory)); throw new ObjectDisposedException(nameof(RealmContextFactory));
// TODO: this can be added for safety once we figure how to bypass in test if (!ThreadSafety.IsUpdateThread)
// if (!ThreadSafety.IsUpdateThread) throw new InvalidOperationException($"{nameof(BlockAllOperations)} must be called from the update thread.");
// throw new InvalidOperationException($"{nameof(BlockAllOperations)} must be called from the update thread.");
Logger.Log(@"Blocking realm operations.", LoggingTarget.Database); Logger.Log(@"Blocking realm operations.", LoggingTarget.Database);