void (@NotNull Disposable disposable) { var manager = (HeadlessDataManager)DataManager.getInstance(); if (manager.myUseProductionDataManager) { throw new IllegalStateException("Already called and still not disposed."); } Disposer.register(disposable, () -> { manager.myUseProductionDataManager = false; }); manager.myUseProductionDataManager = true; }