mirror of
https://github.com/zadam/trilium.git
synced 2025-11-02 11:26:15 +01:00
fix for "Today page does not work for 2021-11-20", closes #2359
This commit is contained in:
@@ -62,6 +62,7 @@ const BUILTIN_ATTRIBUTES = [
|
||||
{ type: 'relation', name: 'renderNote', isDangerous: true }
|
||||
];
|
||||
|
||||
/** @returns {Note[]} */
|
||||
function getNotesWithLabel(name, value) {
|
||||
const query = formatAttrForSearch({type: 'label', name, value}, true);
|
||||
return searchService.searchNotes(query, {
|
||||
@@ -71,6 +72,7 @@ function getNotesWithLabel(name, value) {
|
||||
}
|
||||
|
||||
// TODO: should be in search service
|
||||
/** @returns {Note|null} */
|
||||
function getNoteWithLabel(name, value) {
|
||||
// optimized version (~20 times faster) without using normal search, useful for e.g. finding date notes
|
||||
const attrs = becca.findAttributes('label', name);
|
||||
|
||||
Reference in New Issue
Block a user