Skip to content

Commit 3801b1a

Browse files
committed
fixing some dependencies
1 parent afd6b7a commit 3801b1a

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

packages/compass-indexes/src/components/create-index-fields.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ function CreateIndexFields({
9696
track('New Index Field Added', {
9797
context: 'Create Index Modal',
9898
});
99-
}, []);
99+
}, [onAddFieldClick]);
100100

101101
const comboboxOptions = schemaFields.map((value) => ({ value }));
102102

packages/compass-indexes/src/components/create-index-form/index-flow-section.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ const generateOptimalQueries = (
163163

164164
const optimalQueries = coveredQueriesArr
165165
.slice(0, -2)
166-
.reduce<Record<string, unknown>>((acc, obj, index) => {
166+
.reduce<Record<string, unknown>>((acc, obj) => {
167167
const key = Object.keys(obj)[0];
168168
const value = obj[key];
169169

packages/compass-indexes/src/components/create-index-form/query-flow-section.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ const QueryFlowSection = ({
160160
});
161161

162162
setHasNewChanges(false);
163-
}, [inputQuery, dbName, collectionName, onSuggestedIndexButtonClick]);
163+
}, [inputQuery, dbName, collectionName, onSuggestedIndexButtonClick, track]);
164164

165165
const handleQueryInputChange = useCallback((text: string) => {
166166
setInputQuery(text);

packages/compass-indexes/src/components/create-index-modal/create-index-modal.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ function CreateIndexModal({
6767
});
6868
}
6969
},
70-
[onCancelCreateIndexClick]
70+
[onCancelCreateIndexClick, track]
7171
);
7272

7373
useTrackOnChange(

0 commit comments

Comments
 (0)