fix comment space

This commit is contained in:
Philipinho
2025-10-07 18:44:37 +01:00
parent c9b1cad982
commit 16c1e864af

View File

@ -234,14 +234,20 @@ export class PageService {
);
}
// update spaceId in shares
if (pageIds.length > 0) {
// update spaceId in shares
await trx
.updateTable('shares')
.set({ spaceId: spaceId })
.where('pageId', 'in', pageIds)
.execute();
}
// Update comments
await trx
.updateTable('comments')
.set({ spaceId: spaceId })
.where('pageId', 'in', pageIds)
.execute();
// Update attachments
await this.attachmentRepo.updateAttachmentsByPageId(
@ -249,6 +255,7 @@ export class PageService {
pageIds,
trx,
);
}
});
}