mirror of
https://github.com/zadam/trilium.git
synced 2025-11-03 03:46:37 +01:00
integrate new search into the main global search
This commit is contained in:
@@ -4,15 +4,15 @@ const repository = require('../../services/repository');
|
||||
const noteCacheService = require('../../services/note_cache/note_cache.js');
|
||||
const log = require('../../services/log');
|
||||
const scriptService = require('../../services/script');
|
||||
const searchService = require('../../services/search');
|
||||
const searchService = require('../../services/search/search');
|
||||
|
||||
async function searchNotes(req) {
|
||||
const noteIds = await searchService.searchForNoteIds(req.params.searchString);
|
||||
const notePaths = await searchService.searchNotes(req.params.searchString);
|
||||
|
||||
try {
|
||||
return {
|
||||
success: true,
|
||||
results: noteIds.map(noteCacheService.getNotePath).filter(res => !!res)
|
||||
results: notePaths
|
||||
}
|
||||
}
|
||||
catch {
|
||||
|
||||
Reference in New Issue
Block a user