player: fix protected videos in blink/webkit
parent
b9db596932
commit
f8d2e2d7c4
|
@ -352,8 +352,8 @@ window.addEventListener('DOMContentLoaded', (event) => {
|
|||
|
||||
function handleProtected(e) {
|
||||
console.log(e)
|
||||
if(e.originalTarget.error.code == 4 && ! e.originalTarget.currentSrc.startsWith("https://"+window.location.hostname)) {
|
||||
e.target.src="https://"+window.location.hostname+"/proxy?url="+encodeURIComponent(encodeURIComponent(e.originalTarget.currentSrc))
|
||||
if(e.target.error.code == 4 && ! e.target.currentSrc.startsWith("https://"+window.location.hostname)) {
|
||||
e.target.src="https://"+window.location.hostname+"/proxy?url="+encodeURIComponent(encodeURIComponent(e.target.currentSrc))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue