Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

fix: database migration (#2887)

3720da57fbeaddc7
diff --git a/packages/env/src/blocksuite/subdoc-migration.ts b/packages/env/src/blocksuite/subdoc-migration.ts
index bf41606bd8..b1b3511a06 100644
--- a/packages/env/src/blocksuite/subdoc-migration.ts
+++ b/packages/env/src/blocksuite/subdoc-migration.ts
@@ -39,7 +39,9 @@ function migrateDatabase(data: Y.Map<unknown>) {
update: (cell: { id: string; value: unknown }) => void
) => {
Object.values(cells).forEach(row => {
- update(row[id]);
+ if (row[id] != null) {
+ update(row[id]);
+ }
});
};
const newColumns = columns.map(v => {