Skip to content

fix: prefer exact title match over route-path for slash-containing wi… - #1381

Merged
perber merged 1 commit into
mainfrom
fix/wikilink-slash-title-precedence
Aug 3, 2026
Merged

fix: prefer exact title match over route-path for slash-containing wi…#1381
perber merged 1 commit into
mainfrom
fix/wikilink-slash-title-precedence

Conversation

@perber

@perber perber commented Aug 3, 2026

Copy link
Copy Markdown
Owner

…kilinks

A [[Title]] wikilink whose title contains a "/" (e.g. [[TCP/IP]]) tried a route-path lookup first, only falling back to a title lookup if that failed. This let an unrelated route path silently shadow a real title match, resolving the link to the wrong page with Broken staying false.

resolveWikiLinkTargets now always tries the title lookup first for every target, including slash-containing ones; route-path lookup is only attempted as a fallback when there are zero title matches, which still supports [[some/nested/page]]-style route hints. An ambiguous title match (N>1) is treated the same as the plain-title case (broken), for consistency.

…kilinks

A [[Title]] wikilink whose title contains a "/" (e.g. [[TCP/IP]]) tried
a route-path lookup first, only falling back to a title lookup if that
failed. This let an unrelated route path silently shadow a real
title match, resolving the link to the wrong page with Broken staying
false.

resolveWikiLinkTargets now always tries the title lookup first for
every target, including slash-containing ones; route-path lookup is
only attempted as a fallback when there are zero title matches, which
still supports [[some/nested/page]]-style route hints. An ambiguous
title match (N>1) is treated the same as the plain-title case (broken),
for consistency.
@perber
perber merged commit e7d68a9 into main Aug 3, 2026
9 checks passed
@perber
perber deleted the fix/wikilink-slash-title-precedence branch August 3, 2026 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant