diff --git a/src/Explorer/Controls/Settings/SettingsComponent.tsx b/src/Explorer/Controls/Settings/SettingsComponent.tsx index 4d9531904..bcb2e9cd5 100644 --- a/src/Explorer/Controls/Settings/SettingsComponent.tsx +++ b/src/Explorer/Controls/Settings/SettingsComponent.tsx @@ -299,19 +299,19 @@ export class SettingsComponent extends React.Component { + this.refreshCollectionData(); + }, + (state) => state.indexingPolicies[this.collection.id()], + ); + this.refreshCollectionData(); } this.setBaseline(); if (this.props.settingsTab.isActive()) { useCommandBar.getState().setContextButtons(this.getTabsButtons()); } - this.unsubscribe = useIndexingPolicyStore.subscribe( - () => { - this.refreshCollectionData(); - }, - (state) => state.indexingPolicies[this.collection.id()], - ); - this.refreshCollectionData(); } componentWillUnmount(): void { if (this.unsubscribe) { @@ -873,9 +873,8 @@ export class SettingsComponent extends React.Component