Commit 229a289c authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Exclude redirect too

parent 02646179
......@@ -39,8 +39,10 @@ bool BlockExternalResourcesUrlInterceptor::interceptRequest(QWebEngineUrlRequest
|| scheme == QLatin1String("file")) {
return false;
}
const QWebEngineUrlRequestInfo::ResourceType resourceType = info.resourceType();
const QWebEngineUrlRequestInfo::NavigationType navigationType = info.navigationType();
if (resourceType == QWebEngineUrlRequestInfo::ResourceTypeMedia
|| resourceType == QWebEngineUrlRequestInfo::ResourceTypePing
|| resourceType == QWebEngineUrlRequestInfo::ResourceTypePrefetch
......@@ -62,7 +64,8 @@ bool BlockExternalResourcesUrlInterceptor::interceptRequest(QWebEngineUrlRequest
} else if (navigationType == QWebEngineUrlRequestInfo::NavigationTypeReload
|| navigationType == QWebEngineUrlRequestInfo::NavigationTypeTyped
|| navigationType == QWebEngineUrlRequestInfo::NavigationTypeBackForward
|| navigationType == QWebEngineUrlRequestInfo::NavigationTypeOther) {
|| navigationType == QWebEngineUrlRequestInfo::NavigationTypeOther
|| navigationType == QWebEngineUrlRequestInfo::NavigationTypeRedirect) {
return true;
}
return false;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment