Skip to content

Commit

Permalink
Fix for #71
Browse files Browse the repository at this point in the history
  • Loading branch information
alangrainger committed Sep 30, 2024
1 parent 6622005 commit a2e66f5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/note.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ export default class Note {
el.removeAttribute('href')
continue
} else if (match) {
// A link to another note - check to see if we can link to an already shared note
// This is a link to another note - check to see if we can link to an already shared note
const linkedFile = this.plugin.app.metadataCache.getFirstLinkpathDest(match[1], '')
if (linkedFile instanceof TFile) {
const linkedMeta = this.plugin.app.metadataCache.getFileCache(linkedFile)
Expand All @@ -227,8 +227,8 @@ export default class Note {
}
}
}
// This file is not shared, so remove the link and replace with the non-link content
el.replaceWith(el.innerHTML)
// This linked note is not shared, so remove the link and replace with the non-link content
el.replaceWith(el.innerText)
}
for (const el of this.contentDom.querySelectorAll<HTMLElement>('a.external-link')) {
// Remove target=_blank from external links
Expand Down

0 comments on commit a2e66f5

Please sign in to comment.