Remove DEFAULT_PROXY

This commit is contained in:
Andrea Marchesini
2021-10-22 17:32:04 +02:00
parent 37ed2455eb
commit 3572bebbd9
3 changed files with 3 additions and 21 deletions
+2 -9
View File
@@ -187,21 +187,14 @@ window.assignManager = {
async handleProxifiedRequest(requestInfo) {
// The following blocks potentially dangerous requests for privacy that come without a tabId
// Dupe of Utils.DEFAULT_PROXY, which was occasionally and unreliably
// not being found on startup and causing significant UI grief.
if(requestInfo.tabId === -1) {
return {
value: Object.freeze({type: "direct"}),
writable: false,
enumerable: true,
configurable: false
};
return {type: "direct"};
}
const tab = await browser.tabs.get(requestInfo.tabId);
const result = await proxifiedContainers.retrieve(tab.cookieStoreId);
if (!result || !result.proxy) {
return Utils.DEFAULT_PROXY;
return {type: "direct"};
}
if (!result.proxy.mozProxyEnabled) {