diff --git a/packages/database/src/queries/reports/append-report-content.ts b/packages/database/src/queries/reports/append-report-content.ts index c55d475b7..b69722121 100644 --- a/packages/database/src/queries/reports/append-report-content.ts +++ b/packages/database/src/queries/reports/append-report-content.ts @@ -26,6 +26,7 @@ export const appendReportContent = async ( const result = await db .update(reportFiles) .set({ + // From Nate: I was just thinking we do not KNOW if this is valid markdown... content: sql`${reportFiles.content} || ${content}`, updatedAt: new Date().toISOString(), }) diff --git a/packages/database/src/queries/reports/replace-report-content.ts b/packages/database/src/queries/reports/replace-report-content.ts index 8501687b1..6bac173d8 100644 --- a/packages/database/src/queries/reports/replace-report-content.ts +++ b/packages/database/src/queries/reports/replace-report-content.ts @@ -20,6 +20,7 @@ type ReplaceReportContentInput = z.infer export const replaceReportContent = async ( params: ReplaceReportContentInput ): Promise<{ content: string }> => { + // From Nate: I was just thinking we do not KNOW if this is valid markdown... const { reportId, findString, replaceString } = ReplaceReportContentInputSchema.parse(params); try { diff --git a/packages/database/src/queries/reports/update-report.ts b/packages/database/src/queries/reports/update-report.ts index 8743e3ea8..12ff021d6 100644 --- a/packages/database/src/queries/reports/update-report.ts +++ b/packages/database/src/queries/reports/update-report.ts @@ -64,6 +64,7 @@ export const updateReport = async ( } if (content !== undefined) { + // From Nate: I was just thinking we do not KNOW if this is valid markdown... Maybe we should accept ReportElements and then convert to markdown? Leaving this comment here for now because we are moving fast and I don't want to block the PR. updateData.content = content; }