mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2024-08-16 17:00:31 +03:00
href can be null
This commit is contained in:
parent
79d6e93b03
commit
4ff7880584
@ -40,7 +40,7 @@ export class PluginPagesComponent implements OnDestroy, AfterViewInit {
|
||||
if (!a) return
|
||||
|
||||
// Get the href attribute set by the dev, not the one calculated by JS to detect if it's a relative/external link
|
||||
const href = a.getAttribute('href')
|
||||
const href = a.getAttribute('href') || ''
|
||||
|
||||
if (!a.target && href.startsWith('/')) {
|
||||
event.preventDefault()
|
||||
|
Loading…
Reference in New Issue
Block a user