mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-17 03:31:52 +00:00
check href exists
This commit is contained in:
@@ -55,7 +55,7 @@ function handleAnchorClick (e) {
|
|||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
e.stopPropagation()
|
e.stopPropagation()
|
||||||
let href = e.target.href
|
let href = e.target.href
|
||||||
if (href.match(/^http:\/\/|https:\/\/|mailto:\/\//)) {
|
if (href && href.match(/^http:\/\/|https:\/\/|mailto:\/\//)) {
|
||||||
shell.openExternal(href)
|
shell.openExternal(href)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user