mirror of https://github.com/gorhill/uBlock.git
this fixes #135
This commit is contained in:
parent
28fbda6607
commit
600fa2c3d9
|
@ -72,9 +72,11 @@ return {
|
||||||
netWhitelist: {},
|
netWhitelist: {},
|
||||||
netWhitelistModifyTime: 0,
|
netWhitelistModifyTime: 0,
|
||||||
netWhitelistDefault: [
|
netWhitelistDefault: [
|
||||||
|
'about-scheme',
|
||||||
'behind-the-scene',
|
'behind-the-scene',
|
||||||
'chrome-extension-scheme',
|
'chrome-extension-scheme',
|
||||||
'chrome-scheme',
|
'chrome-scheme',
|
||||||
|
'loopconversation.about-scheme',
|
||||||
'opera-scheme',
|
'opera-scheme',
|
||||||
''
|
''
|
||||||
].join('\n').trim(),
|
].join('\n').trim(),
|
||||||
|
|
|
@ -81,6 +81,16 @@ var onVersionReady = function(lastVersion) {
|
||||||
);
|
);
|
||||||
µb.saveWhitelist();
|
µb.saveWhitelist();
|
||||||
}
|
}
|
||||||
|
// https://github.com/gorhill/uBlock/issues/135#issuecomment-96677379
|
||||||
|
// `about:loopconversation` is used by Firefox for its Hello service
|
||||||
|
if ( lastVersion.localeCompare('0.9.5.2') < 0 ) {
|
||||||
|
µb.netWhitelist = µb.whitelistFromString(
|
||||||
|
µb.stringFromWhitelist(µb.netWhitelist) +
|
||||||
|
'\n' +
|
||||||
|
'loopconversation.about-scheme'
|
||||||
|
);
|
||||||
|
µb.saveWhitelist();
|
||||||
|
}
|
||||||
if ( lastVersion !== vAPI.app.version ) {
|
if ( lastVersion !== vAPI.app.version ) {
|
||||||
vAPI.storage.set({ version: vAPI.app.version });
|
vAPI.storage.set({ version: vAPI.app.version });
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,13 +55,15 @@ var µb = µBlock;
|
||||||
return uri.normalizedURI();
|
return uri.normalizedURI();
|
||||||
}
|
}
|
||||||
|
|
||||||
var url = 'http://' + scheme + '-scheme/';
|
var fakeHostname = scheme + '-scheme';
|
||||||
|
|
||||||
if ( uri.hostname !== '' ) {
|
if ( uri.hostname !== '' ) {
|
||||||
url += uri.hostname + '/';
|
fakeHostname = uri.hostname + '.' + fakeHostname;
|
||||||
|
} else if ( scheme === 'about' && uri.path !== '' ) {
|
||||||
|
fakeHostname = uri.path + '.' + fakeHostname;
|
||||||
}
|
}
|
||||||
|
|
||||||
return url;
|
return 'http://' + fakeHostname + '/';
|
||||||
};
|
};
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
Loading…
Reference in New Issue