Don't "instantly" navigate to avoid Google Idiocy™ (closes #936)

This commit is contained in:
Tim "timmyRS" Speckhals 2020-02-16 13:04:36 +01:00
parent 3fef9202b6
commit 9bfb26fa8a

View File

@ -5,26 +5,14 @@ getRedirect=(url,referer,safe_in)=>{
{
return
}
let redirectUrl
if(safe_in===undefined&&(instantNavigation||(referer=="tracker"&&instantNavigationTrackers)))
let redirectUrl=brws.runtime.getURL("html/before-navigate.html")+"?target="+encodeURIComponent(url)
if(referer)
{
redirectUrl=(new URL(url)).toString()
if(referer)
{
refererCache[redirectUrl]=referer
}
redirectUrl+="&referer="+referer
}
else
if(safe_in!==undefined)
{
redirectUrl=brws.runtime.getURL("html/before-navigate.html")+"?target="+encodeURIComponent(url)
if(referer)
{
redirectUrl+="&referer="+referer
}
if(safe_in!==undefined)
{
redirectUrl+="&safe_in="+safe_in
}
redirectUrl+="&safe_in="+safe_in
}
countIt()
return {redirectUrl}