feat: add error message for lighthouse
This commit is contained in:
parent
6c2a093842
commit
bb0c574893
@ -0,0 +1,2 @@
|
|||||||
|
-- AlterTable
|
||||||
|
ALTER TABLE "WebsiteLighthouseReport" ADD COLUMN "errorMessage" TEXT;
|
@ -264,6 +264,7 @@ model WebsiteLighthouseReport {
|
|||||||
accessibilityScore Int @default(0)
|
accessibilityScore Int @default(0)
|
||||||
bestPracticesScore Int @default(0)
|
bestPracticesScore Int @default(0)
|
||||||
seoScore Int @default(0)
|
seoScore Int @default(0)
|
||||||
|
errorMessage String?
|
||||||
|
|
||||||
@@index([createdAt])
|
@@index([createdAt])
|
||||||
@@index([websiteId])
|
@@index([websiteId])
|
||||||
|
@ -14,4 +14,5 @@ export const WebsiteLighthouseReportModelSchema = z.object({
|
|||||||
accessibilityScore: z.number().int(),
|
accessibilityScore: z.number().int(),
|
||||||
bestPracticesScore: z.number().int(),
|
bestPracticesScore: z.number().int(),
|
||||||
seoScore: z.number().int(),
|
seoScore: z.number().int(),
|
||||||
|
errorMessage: z.string().nullish(),
|
||||||
})
|
})
|
||||||
|
@ -649,6 +649,7 @@ export const websiteRouter = router({
|
|||||||
},
|
},
|
||||||
data: {
|
data: {
|
||||||
status: WebsiteLighthouseReportStatus.Failed,
|
status: WebsiteLighthouseReportStatus.Failed,
|
||||||
|
errorMessage: String(err),
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user