Update utils.ts

pull/34330/head
freearhey 1 month ago
parent 850a6beeb8
commit e79445e28d

@ -2,8 +2,8 @@ import normalizeUrl from 'normalize-url'
export function isURI(string: string): boolean {
try {
new URL(string)
return true
const url = new URL(string)
return /^(http:|https:|mmsh:|rtsp:|rtmp:)/.test(url.protocol)
} catch {
return false
}

Loading…
Cancel
Save