Skip to content

Commit bfadc37

Browse files
authored
Merge pull request #65 from janniks/experimental
Add experimental `syncRecordValues` fix
2 parents 6a1af2e + 0f53b47 commit bfadc37

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

src/api/notion.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -129,12 +129,11 @@ export const fetchBlocks = async (
129129
return await fetchNotionData<LoadPageChunkData>({
130130
resource: "syncRecordValues",
131131
body: {
132-
recordVersionMap: {
133-
block: blockList.reduce((obj, blockId) => {
134-
obj[blockId] = -1;
135-
return obj;
136-
}, {} as { [key: string]: -1 }),
137-
},
132+
requests: blockList.map((id) => ({
133+
id,
134+
table: "block",
135+
version: -1,
136+
})),
138137
},
139138
notionToken,
140139
});

0 commit comments

Comments
 (0)