Permalink
Browse files

release was already being emitted, all tests pass

  • Loading branch information...
1 parent 2478e78 commit eaaebd4dc161c457430b96748acb109d93f7e1ea @substack committed Jan 2, 2011
Showing with 0 additions and 5 deletions.
  1. +0 −5 index.js
View
@@ -56,10 +56,6 @@ function Resources () {
self.release = function (token) {
delete tokens[token];
- if (emitters[token]) {
- emitters[token]('release');
- }
- delete emitters[token];
var i = queue.map(function (q) { return q.token }).indexOf(token);
if (i >= 0) { // in the queue
@@ -103,7 +99,6 @@ function Resources () {
res.lease.end = res.lease.start + ms;
res.emit = emit;
- emitters[token] = emit;
if (ms > 0) {
setTimeout(function () {
emit('expire');

0 comments on commit eaaebd4

Please sign in to comment.