fix: lint warning

This commit is contained in:
JimmFly
2022-12-15 17:45:12 +08:00
parent 38570ff8e7
commit d7abd069c7
@@ -25,7 +25,7 @@ export const Results = (props: {
setResults(search(query));
setLoading(false);
//Save the Map<BlockId, PageId> obtained from the search as state
}, [query, search]);
}, [query, search, setLoading]);
const pageIds = [...results.values()];
const resultsPageMeta = pageList.filter(
@@ -35,7 +35,7 @@ export const Results = (props: {
useEffect(() => {
setShowCreatePage(resultsPageMeta.length ? false : true);
//Determine whether to display the + New page
}, [resultsPageMeta]);
}, [resultsPageMeta, setShowCreatePage]);
return loading ? null : (
<Command.List>