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

Unified Diff: lib/subscriptionClasses.js

Issue 6341149593698304: Issue 301 - Change for each to for .. of .. in lib/ (Closed)
Patch Set: Created April 10, 2014, 5:02 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 | « lib/requestNotifier.js ('k') | lib/sync.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/subscriptionClasses.js
===================================================================
--- a/lib/subscriptionClasses.js
+++ b/lib/subscriptionClasses.js
@@ -124,17 +124,17 @@ Subscription.prototype =
if (this._fixedTitle)
buffer.push("fixedTitle=true");
if (this._disabled)
buffer.push("disabled=true");
},
serializeFilters: function(buffer)
{
- for each (let filter in this.filters)
+ for (let filter of this.filters)
buffer.push(filter.text.replace(/\[/g, "\\["));
},
toString: function()
{
let buffer = [];
this.serialize(buffer);
return buffer.join("\n");
@@ -269,17 +269,17 @@ SpecialSubscription.prototype =
* Tests whether a filter should be added to this group by default
* @param {Filter} filter filter to be tested
* @return {Boolean}
*/
isDefaultFor: function(filter)
{
if (this.defaults && this.defaults.length)
{
- for each (let type in this.defaults)
+ for (let type of this.defaults)
{
if (filter instanceof SpecialSubscription.defaultsMap[type])
return true;
if (!(filter instanceof ActiveFilter) && type == "blacklist")
return true;
}
}
« no previous file with comments | « lib/requestNotifier.js ('k') | lib/sync.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld