From 32e8bc783703d3a4bb7e8bb4c22d5669ce9d8b87 Mon Sep 17 00:00:00 2001 From: gilles Date: Sun, 13 Sep 2026 17:40:32 +0200 Subject: [PATCH] refactor(notes): rename candidate variable in isNote guard --- src/lib/notesStorage.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lib/notesStorage.ts b/src/lib/notesStorage.ts index d09d29d..d9b69fd 100644 --- a/src/lib/notesStorage.ts +++ b/src/lib/notesStorage.ts @@ -21,10 +21,10 @@ export function saveNotes(notes: Note[]): void { function isNote(value: unknown): value is Note { if (typeof value !== 'object' || value === null) return false - const candidate = value as Record + const note = value as Record return ( - typeof candidate.id === 'number' && - typeof candidate.title === 'string' && - typeof candidate.content === 'string' + typeof note.id === 'number' && + typeof note.title === 'string' && + typeof note.content === 'string' ) }