implemented destroy & updated disconnect

This commit is contained in:
Kevin Jahns
2016-02-16 15:51:12 +01:00
parent bd54a43a33
commit da7e67d97d
3 changed files with 27 additions and 5 deletions

View File

@@ -46,6 +46,12 @@ module.exports = function (Y /* : any*/) {
this.onevent = onevent
this.eventListeners = []
}
destroy () {
this.waiting = null
this.awaiting = null
this.onevent = null
this.eventListeners = null
}
/*
Call this when a new operation arrives. It will be executed right away if
there are no waiting operations, that you prematurely executed