mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
Merge pull request #3075 from sigaloid/master
Filter excludeFromNoteMap from backlinks
This commit is contained in:
commit
9ce0421ae7
@ -299,7 +299,7 @@ function getBacklinks(req) {
|
||||
|
||||
let backlinksWithExcerptCount = 0;
|
||||
|
||||
return backlinks.map(backlink => {
|
||||
return backlinks.filter(note => !note.getNote().hasLabel('excludeFromNoteMap')).map(backlink => {
|
||||
const sourceNote = backlink.note;
|
||||
|
||||
if (sourceNote.type !== 'text' || backlinksWithExcerptCount > 50) {
|
||||
|
@ -315,7 +315,7 @@ function getBacklinkCount(req) {
|
||||
}
|
||||
else {
|
||||
return {
|
||||
count: note.getTargetRelations().length
|
||||
count: note.getTargetRelations().filter(note => !note.getNote().hasLabel('excludeFromNoteMap')).length
|
||||
};
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user