Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

fix params not used correctly

ammarahm-eddeaf06c3665c
diff --git a/apps/mobile/src/views/Notes/index.js b/apps/mobile/src/views/Notes/index.js
index 34fa46d82..b620be02f 100644
--- a/apps/mobile/src/views/Notes/index.js
+++ b/apps/mobile/src/views/Notes/index.js
@@ -52,9 +52,9 @@ export const Notes = ({route, navigation}) => {
const loading = useNoteStore(state => state.loading);
const alias =
params.current?.type === 'tag'
- ? db.tags.alias(params.id)
+ ? db.tags.alias(params.current?.id)
: params.current?.type === 'color'
- ? db.colors.alias(params.id)
+ ? db.colors.alias(params.current?.id)
: params.current?.title;
const onLoad = () => {
@@ -185,7 +185,7 @@ export const Notes = ({route, navigation}) => {
if (params.current?.type !== 'topic') return;
eSendEvent(eOpenAddTopicDialog, {
notebookId: params.current?.notebookId,
- toEdit: params
+ toEdit: params.current
});
},
icon: 'pencil'
@@ -225,7 +225,7 @@ export const Notes = ({route, navigation}) => {
if (params.current?.type !== 'topic') return;
eSendEvent(eOpenAddTopicDialog, {
notebookId: params.current?.notebookId,
- toEdit: params
+ toEdit: params.current
});
}
}