Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: js/desktop-options.js

Issue 29736629: Issue 6532 - Removes required subscription title input field (Closed) Base URL: https://hg.adblockplus.org/adblockplusui
Patch Set: Address PS1 comments Created April 3, 2018, 9:47 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: js/desktop-options.js
===================================================================
--- a/js/desktop-options.js
+++ b/js/desktop-options.js
@@ -732,18 +732,17 @@
break;
case "validate-import-subscription":
let form = findParentData(element, "validation", true);
if (!form)
return;
if (form.checkValidity())
{
- addEnableSubscription(E("import-list-url").value,
- E("import-list-title").value);
+ addEnableSubscription(E("import-list-url").value);
form.reset();
closeDialog();
}
else
{
form.querySelector(":invalid").focus();
}
break;
@@ -1224,31 +1223,29 @@
text: "@@||" + host.toLowerCase() + "^$document"
});
}
domain.value = "";
E("whitelisting-add-button").disabled = true;
}
-function addEnableSubscription(url, title, homepage)
Thomas Greiner 2018/04/06 13:57:27 Please don't change the signature of this function
Jon Sonesen 2018/04/09 04:12:01 Acknowledged. I did dig around the code in this fi
Thomas Greiner 2018/04/09 11:26:59 It's called in line 584 as `addEnableSubscription(
Thomas Greiner 2018/04/27 09:48:46 No need to remove the "homepage" argument as part
+function addEnableSubscription(url, homepage)
{
let messageType = null;
let knownSubscription = subscriptionsMap[url];
if (knownSubscription && knownSubscription.disabled == true)
messageType = "subscriptions.toggle";
else
messageType = "subscriptions.add";
let message = {
type: messageType,
url
};
- if (title)
- message.title = title;
if (homepage)
message.homepage = homepage;
browser.runtime.sendMessage(message);
}
function onFilterMessage(action, filter)
{

Powered by Google App Engine
This is Rietveld