Skip to content

armgit / memos

Public Imported from GitHub
0

Memos is an open-source, self-hosted note-taking app that brings your everyday thoughts together in a personal timeline. Your data stays yours, and you choose what to keep private or share.

chore: update MemoRelationListView.tsx (#1933)

Sergei Vassiljev934f57c92f48
diff --git a/web/src/components/MemoRelationListView.tsx b/web/src/components/MemoRelationListView.tsx
index 74b941ebd..cd25584eb 100644
--- a/web/src/components/MemoRelationListView.tsx
+++ b/web/src/components/MemoRelationListView.tsx
@@ -13,10 +13,10 @@ const MemoRelationListView = (props: Props) => {
useEffect(() => {
const fetchRelatedMemoList = async () => {
- const requests = relationList.map((relation) => memoCacheStore.getOrFetchMemoById(relation.relatedMemoId));
- const memoList = await Promise.all(requests);
+ const memoList = await Promise.all(relationList.map((relation) => memoCacheStore.getOrFetchMemoById(relation.relatedMemoId)));
setRelatedMemoList(memoList);
};
+
fetchRelatedMemoList();
}, [relationList]);