Remove block_url feature to increase websites compatibility

This commit is contained in:
2020-08-29 17:57:39 +02:00
parent 630a3f9cb9
commit 90e9862982
8 changed files with 2 additions and 206 deletions

View File

@@ -236,7 +236,6 @@ function block_all_forms(doc, do_block)
{
if (do_block)
{
block_url(form.action);
old_cb = form.onsubmit;
if (old_cb)
form.removeEventListener("submit", old_cb);
@@ -254,10 +253,6 @@ function block_all_forms(doc, do_block)
}
}
}
/* Request can be sent to another URL... */
if (managed_forms.length && do_block)
block_url("<all_urls>");
}
function unblock_all_forms()
@@ -271,7 +266,6 @@ function unblock_all_forms()
var form = managed_forms[i];
form.removeEventListener("submit", on_sumbit);
unblock_url(form.action);
var fields = form.getElementsByTagName("input");
for (var a=0; a<fields.length; a++)
@@ -286,9 +280,6 @@ function unblock_all_forms()
}
}
if (managed_forms.length)
unblock_url("<all_urls>");
gpass_enabled = false;
}

View File

@@ -34,18 +34,6 @@ function notify(text, data)
browser.runtime.sendMessage({type: "notification", options:{"message":text, "data":data}});
}
function block_url(url)
{
debug("Block URL " + url);
browser.runtime.sendMessage({type: "block_url", options:{"url":url}});
}
function unblock_url(url)
{
debug("Unblock URL " + url);
browser.runtime.sendMessage({type: "unblock_url", options:{"url":url}});
}
// https://stackoverflow.com/questions/6965107/converting-between-strings-and-arraybuffers
function ab2str(buf) {
return String.fromCharCode.apply(null, new Uint8Array(buf));