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

Unified Diff: options.js

Issue 29339613: Issue 3907 - Make sure that the title of Acceptable Ads subscription used (Closed)
Patch Set: Created April 8, 2016, 4: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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: options.js
===================================================================
--- a/options.js
+++ b/options.js
@@ -65,12 +65,11 @@
Collection.prototype._getItemTitle = function(item, i)
{
- var title = null;
- if (this.details[i].useOriginalTitle)
- title = item.originalTitle;
- if (!title)
- title = item.title || item.url || item.text;
- return title;
+ if (item.url == acceptableAdsUrl)
+ return getMessage("options_acceptableAds_description");
+ if (this.details[i].useOriginalTitle && item.originalTitle)
+ return item.originalTitle;
+ return item.title || item.url || item.text;
};
Collection.prototype.addItems = function()
@@ -872,8 +871,7 @@
acceptableAdsUrl = url;
updateSubscription({
url: acceptableAdsUrl,
- disabled: true,
- title: getMessage("options_acceptableAds_description")
+ disabled: true
});
// Load user subscriptions
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld