Skip to content

Commit

Permalink
Merge pull request #16833 from bekzod/remove-arg
Browse files Browse the repository at this point in the history
remove redundant args to `beginPropertyChanges/endPropertyChanges`
  • Loading branch information
krisselden committed Aug 6, 2018
2 parents 9ea80e1 + 148af4d commit 04dec4f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions packages/ember-metal/tests/observer_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -304,10 +304,10 @@ moduleFor(
fooCount++;
});

beginPropertyChanges(obj);
beginPropertyChanges();
set(obj, 'foo', 'BIFF');
set(obj, 'foo', 'BAZ');
endPropertyChanges(obj);
endPropertyChanges();

assert.equal(fooCount, 1, 'foo should have fired once');
}
Expand Down
8 changes: 4 additions & 4 deletions packages/ember-runtime/lib/mixins/array.js
Original file line number Diff line number Diff line change
Expand Up @@ -1500,11 +1500,11 @@ const MutableArray = Mixin.create(ArrayMixin, MutableEnumerable, {
@public
*/
removeObjects(objects) {
beginPropertyChanges(this);
beginPropertyChanges();
for (let i = objects.length - 1; i >= 0; i--) {
this.removeObject(objects[i]);
}
endPropertyChanges(this);
endPropertyChanges();
return this;
},

Expand Down Expand Up @@ -1543,9 +1543,9 @@ const MutableArray = Mixin.create(ArrayMixin, MutableEnumerable, {
@public
*/
addObjects(objects) {
beginPropertyChanges(this);
beginPropertyChanges();
objects.forEach(obj => this.addObject(obj));
endPropertyChanges(this);
endPropertyChanges();
return this;
},
});
Expand Down

0 comments on commit 04dec4f

Please sign in to comment.