|
|
@ -443,12 +443,12 @@ vAPI.net.registerListeners = function() {
|
|
|
|
details.hostname = µburi.hostnameFromURI(details.url);
|
|
|
|
details.hostname = µburi.hostnameFromURI(details.url);
|
|
|
|
|
|
|
|
|
|
|
|
// The rest of the function code is to normalize type
|
|
|
|
// The rest of the function code is to normalize type
|
|
|
|
var type = details.type;
|
|
|
|
if ( details.type !== 'other' ) {
|
|
|
|
if ( type !== 'other' ) {
|
|
|
|
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
var path = µburi.path;
|
|
|
|
|
|
|
|
var pos = path.lastIndexOf('.');
|
|
|
|
var tail = µburi.path.slice(-6);
|
|
|
|
|
|
|
|
var pos = tail.lastIndexOf('.');
|
|
|
|
|
|
|
|
|
|
|
|
// https://github.com/gorhill/uBlock/issues/862
|
|
|
|
// https://github.com/gorhill/uBlock/issues/862
|
|
|
|
// If no transposition possible, transpose to `object` as per
|
|
|
|
// If no transposition possible, transpose to `object` as per
|
|
|
@ -458,7 +458,7 @@ vAPI.net.registerListeners = function() {
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
var ext = path.slice(pos) + '.';
|
|
|
|
var ext = tail.slice(pos) + '.';
|
|
|
|
if ( '.eot.ttf.otf.svg.woff.woff2.'.indexOf(ext) !== -1 ) {
|
|
|
|
if ( '.eot.ttf.otf.svg.woff.woff2.'.indexOf(ext) !== -1 ) {
|
|
|
|
details.type = 'font';
|
|
|
|
details.type = 'font';
|
|
|
|
return;
|
|
|
|
return;
|
|
|
@ -470,10 +470,7 @@ vAPI.net.registerListeners = function() {
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// https://code.google.com/p/chromium/issues/detail?id=410382
|
|
|
|
// https://code.google.com/p/chromium/issues/detail?id=410382
|
|
|
|
if ( type === 'other' ) {
|
|
|
|
|
|
|
|
details.type = 'object';
|
|
|
|
details.type = 'object';
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
var onBeforeRequestClient = this.onBeforeRequest.callback;
|
|
|
|
var onBeforeRequestClient = this.onBeforeRequest.callback;
|
|
|
|