diff --git a/src/routes/api/search.js b/src/routes/api/search.js index 177e9fc6b..4e8a428a1 100644 --- a/src/routes/api/search.js +++ b/src/routes/api/search.js @@ -58,7 +58,13 @@ async function searchFromNote(req) { searchResultNoteIds = await searchFromRelation(note, relationName); } else { - searchResultNoteIds = searchService.searchNotes(json.searchString) + const searchContext = new SearchContext({ + includeNoteContent: true, + excludeArchived: true, + fuzzyAttributeSearch: false + }); + + searchResultNoteIds = searchService.findNotesWithQuery(json.searchString, searchContext) .map(sr => sr.noteId); } }