diff --git a/packages/backend/src/models/LatestNote.ts b/packages/backend/src/models/LatestNote.ts index 5cce09e556..24cb9607b0 100644 --- a/packages/backend/src/models/LatestNote.ts +++ b/packages/backend/src/models/LatestNote.ts @@ -36,10 +36,8 @@ export class LatestNote { public note: MiNote | null; constructor(data: Partial) { - if (data == null) return; - for (const [k, v] of Object.entries(data)) { - (this as any)[k] = v; + (this as Record)[k] = v; } } }