routes: fix internal link detection
it just checked link length, but should at least ensure that the condition which checks for internal links starts with a slash.pull/84/head
parent
80d3a3f6a7
commit
25d3283a80
|
@ -317,7 +317,7 @@ const handleLink = (a: HTMLAnchorElement, e: MouseEvent) => {
|
|||
|| href.startsWith('/feed')
|
||||
|| href.startsWith('/note')
|
||||
|| href.startsWith('/npub')
|
||||
|| href.length === 65
|
||||
|| (href.startsWith('/') && href.length === 65)
|
||||
) {
|
||||
route(href);
|
||||
history.pushState({}, '', href);
|
||||
|
|
Loading…
Reference in New Issue