Skip to content

Build your personal knowledge base with Trilium Notes

Apply suggestions from code review

Elian Doran57f220e64c1b
diff --git a/apps/client/src/services/attributes.ts b/apps/client/src/services/attributes.ts
index 7fad049470..13f440c3cf 100644
--- a/apps/client/src/services/attributes.ts
+++ b/apps/client/src/services/attributes.ts
@@ -69,7 +69,7 @@ function removeOwnedLabelByName(note: FNote, labelName: string) {
* @returns `true` if an attribute was identified and removed, `false` otherwise.
*/
function removeOwnedRelationByName(note: FNote, relationName: string) {
- const label = note.getOwnedRelation(relationName);
+ const relation = note.getOwnedRelation(relationName);
if (label) {
removeAttributeById(note.noteId, label.attributeId);
return true;
diff --git a/apps/client/src/services/load_results.ts b/apps/client/src/services/load_results.ts
index 3e00e4a0f9..899560de42 100644
--- a/apps/client/src/services/load_results.ts
+++ b/apps/client/src/services/load_results.ts
@@ -7,7 +7,7 @@ import type { EntityChange } from "../server_types.js";
interface NoteRow {
blobId: string;
dateCreated: string;
- dateMOdified: string;
+ dateModified: string;
isDeleted?: boolean;
isProtected?: boolean;
mime: string;
diff --git a/apps/client/src/widgets/collections/board/index.tsx b/apps/client/src/widgets/collections/board/index.tsx
index e34ef12259..7b939224d5 100644
--- a/apps/client/src/widgets/collections/board/index.tsx
+++ b/apps/client/src/widgets/collections/board/index.tsx
@@ -268,7 +268,7 @@ export function TitleEditor({ currentValue, placeholder, save, dismiss, mode, is
}
};
- const onBlur = (newValue) => {
+ const onBlur = (newValue: string) => {
if (!shouldDismiss.current && newValue.trim() && (newValue !== currentValue || isNewItem)) {
save(newValue);
dismissOnNextRefreshRef.current = true;
@@ -311,6 +311,6 @@ export function TitleEditor({ currentValue, placeholder, save, dismiss, mode, is
dismiss();
}}
/>
- )
+ );
}
}