A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
core: fix extracting internal links
Ammar Ahmed4fc5ec00ae98
diff --git a/packages/core/src/utils/content-block.ts b/packages/core/src/utils/content-block.tsindex f57827e19..58443c460 100644--- a/packages/core/src/utils/content-block.ts+++ b/packages/core/src/utils/content-block.ts@@ -26,7 +26,7 @@ export function extractInternalLinks(block: ContentBlock) {const links: InternalLinkWithOffset[] = [];for (const match of matches || []) {- if (!match.index) continue;+ if (match.index === undefined) continue;const url = match[1].slice(0, match[1].indexOf("|"));const text = match[1].slice(match[1].indexOf("|") + 1);const link = parseInternalLink(url);