diff --git a/apps/api/src/controllers/v1/crawl-status.ts b/apps/api/src/controllers/v1/crawl-status.ts index 7b94f07a..845f616c 100644 --- a/apps/api/src/controllers/v1/crawl-status.ts +++ b/apps/api/src/controllers/v1/crawl-status.ts @@ -103,7 +103,9 @@ export async function crawlStatusController(req: RequestWithAuth 0) { if (!doneJobs[0].data.pageOptions.includeRawHtml) { for (let ii = 0; ii < doneJobs.length; ii++) { - delete data[ii].rawHtml; + if (data[ii]) { + delete data[ii].rawHtml; + } } } }