Skip to content

Commit

Permalink
Merge pull request #83 from jsnajdr/master
Browse files Browse the repository at this point in the history
Subscribe to the renamed transport events
  • Loading branch information
janodvarko authored Aug 19, 2016
2 parents c5554cc + 928957f commit 557bdb1
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lib/transport-observer.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,11 @@ const TransportObserver = Class(
transport.on("onBulkPacket", this.onBulkPacket);
transport.on("startBulkSend", this.startBulkSend);
transport.on("onClosed", this.onClosed);

transport.on("packet", this.onPacket);
transport.on("bulkpacket", this.onBulkPacket);
transport.on("startbulksend", this.startBulkSend);
transport.on("close", this.onClosed);
},

destroy: function() {
Expand All @@ -59,6 +64,11 @@ const TransportObserver = Class(
transport.off("onBulkPacket", this.onBulkPacket);
transport.off("startBulkSend", this.startBulkSend);
transport.off("onClosed", this.onClosed);

transport.off("packet", this.onPacket);
transport.off("bulkpacket", this.onBulkPacket);
transport.off("startbulksend", this.startBulkSend);
transport.off("close", this.onClosed);
},

// Connection Events
Expand Down

0 comments on commit 557bdb1

Please sign in to comment.