metal-events
Advanced tools
Comparing version 2.5.16 to 2.5.17
{ | ||
"name": "metal-events", | ||
"version": "2.5.16", | ||
"version": "2.5.17", | ||
"description": "Classes responsible for emitting and listening to events", | ||
@@ -25,3 +25,3 @@ "license": "BSD", | ||
"dependencies": { | ||
"metal": "^2.5.12" | ||
"metal": "^2.5.17" | ||
}, | ||
@@ -28,0 +28,0 @@ "devDependencies": { |
@@ -75,3 +75,3 @@ 'use strict'; | ||
const events = this.toEventsArray_(event); | ||
for (var i = 0; i < events.length; i++) { | ||
for (let i = 0; i < events.length; i++) { | ||
this.addSingleListener_(events[i], listener, opt_default); | ||
@@ -196,3 +196,3 @@ } | ||
const events = this.toEventsArray_(event); | ||
for (var i = 0; i < events.length; i++) { | ||
for (let i = 0; i < events.length; i++) { | ||
this.many_(events[i], amount, listener); | ||
@@ -215,3 +215,3 @@ } | ||
many_(event, amount, listener) { | ||
var self = this; | ||
const self = this; | ||
@@ -260,3 +260,3 @@ if (amount <= 0) { | ||
const events = this.toEventsArray_(event); | ||
for (var i = 0; i < events.length; i++) { | ||
for (let i = 0; i < events.length; i++) { | ||
this.events_[events[i]] = this.removeMatchingListenerObjs_( | ||
@@ -311,4 +311,4 @@ toArray(this.events_[events[i]]), | ||
if (opt_events) { | ||
var events = this.toEventsArray_(opt_events); | ||
for (var i = 0; i < events.length; i++) { | ||
const events = this.toEventsArray_(opt_events); | ||
for (let i = 0; i < events.length; i++) { | ||
this.events_[events[i]] = null; | ||
@@ -333,3 +333,3 @@ } | ||
const finalListeners = []; | ||
for (var i = 0; i < listenerObjs.length; i++) { | ||
for (let i = 0; i < listenerObjs.length; i++) { | ||
if (!this.matchesListener_(listenerObjs[i], listener)) { | ||
@@ -362,3 +362,3 @@ finalListeners.push(listenerObjs[i]); | ||
handlers = toArray(handlers); | ||
for (var i = 0; i < handlers.length; i++) { | ||
for (let i = 0; i < handlers.length; i++) { | ||
handlers[i](event); | ||
@@ -365,0 +365,0 @@ } |
@@ -117,4 +117,4 @@ 'use strict'; | ||
if (this.proxiedEvents_) { | ||
var events = Object.keys(this.proxiedEvents_); | ||
for (var i = 0; i < events.length; i++) { | ||
const events = Object.keys(this.proxiedEvents_); | ||
for (let i = 0; i < events.length; i++) { | ||
this.proxiedEvents_[events[i]].removeListener(); | ||
@@ -134,3 +134,3 @@ } | ||
setOriginEmitter(originEmitter) { | ||
var events = this.originEmitter_ && this.proxiedEvents_ ? | ||
const events = this.originEmitter_ && this.proxiedEvents_ ? | ||
Object.keys(this.proxiedEvents_) : | ||
@@ -137,0 +137,0 @@ this.pendingEvents_; |
@@ -30,3 +30,3 @@ 'use strict'; | ||
add() { | ||
for (var i = 0; i < arguments.length; i++) { | ||
for (let i = 0; i < arguments.length; i++) { | ||
this.eventHandles_.push(arguments[i]); | ||
@@ -48,3 +48,3 @@ } | ||
removeAllListeners() { | ||
for (var i = 0; i < this.eventHandles_.length; i++) { | ||
for (let i = 0; i < this.eventHandles_.length; i++) { | ||
this.eventHandles_[i].removeListener(); | ||
@@ -51,0 +51,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
52475
Updatedmetal@^2.5.17