Skip to content

Commit feabaa2

Browse files
committed
Replace a now empty concat w/ clone
Signed-off-by: Nick Semenkovich <semenko@alum.mit.edu>
1 parent 5eaa558 commit feabaa2

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

chromium/rules.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,8 +190,11 @@ RuleSets.prototype = {
190190

191191
var tmp, t;
192192
var results = [];
193-
if (this.targets[host])
194-
results = results.concat(this.targets[host]);
193+
if (this.targets[host]) {
194+
// Copy the host targets so we don't modify them.
195+
results = this.targets[host].slice();
196+
}
197+
195198
// replace each portion of the domain with a * in turn
196199
var segmented = host.split(".");
197200
for (var i = 0; i < segmented.length; ++i) {

0 commit comments

Comments
 (0)