禁止打开非http协议链接
This commit is contained in:
@@ -232,6 +232,7 @@ export const objectDeepMerge = (target, source, mergedObj) => {
|
||||
* @param {*} url
|
||||
*/
|
||||
export const openUrl = url => {
|
||||
if (!/^https?:\/\//.test(url)) return
|
||||
shell.openExternal(url)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user