mirror of
https://github.com/zadam/trilium.git
synced 2024-11-12 10:44:42 +08:00
fix duplication of search results when conforming to multiple expressions in OR relation, closes #1262
This commit is contained in:
parent
bdebb35f62
commit
1fcb99fa60
1 changed files with 6 additions and 2 deletions
|
@ -31,8 +31,12 @@ class NoteSet {
|
|||
}
|
||||
|
||||
mergeIn(anotherNoteSet) {
|
||||
this.notes = this.notes.concat(anotherNoteSet.notes);
|
||||
this.noteIdSet = new Set(this.notes.map(note => note.noteId));
|
||||
for (const note of anotherNoteSet.notes) {
|
||||
if (!this.noteIdSet.has(note.noteId)) {
|
||||
this.noteIdSet.add(note.noteId);
|
||||
this.notes.push(note);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
minus(anotherNoteSet) {
|
||||
|
|
Loading…
Reference in a new issue