Just store array of listeners, count is no longer needed. (#4842)

* Just store array of listeners, count is no longer needed.

* Remove unused code
This commit is contained in:
Per Liedman
2016-08-25 17:23:58 +02:00
committed by Vladimir Agafonkin
parent b00f6e0a97
commit 017d29c4eb
2 changed files with 11 additions and 24 deletions

View File

@ -377,11 +377,7 @@ describe('Events', function () {
obj.removeEventListener('test', removeSpy);
// expect(obj.listens('test', L.Util.falseFn)).to.be(false);
// Remove the expect below and comment out the one above, once we've
// gotten rid of _events.count (which makes the expect above pass).
var listeners = obj._events['test'];
expect(listeners.count === listeners.listeners.length).to.be(true);
expect(obj.listens('test')).to.be(false);
});
});