Browse Source

Fixed clearTimeout to check if timer is a Timer

v0.7.4-release
Charles Lehner 15 years ago
committed by Ryan Dahl
parent
commit
caf22c8e0a
  1. 4
      src/node.js

4
src/node.js

@ -443,7 +443,9 @@ GLOBAL.setInterval = function (callback, repeat) {
}; };
GLOBAL.clearTimeout = function (timer) { GLOBAL.clearTimeout = function (timer) {
timer.stop(); if (timer instanceof process.Timer) {
timer.stop();
}
}; };
GLOBAL.clearInterval = GLOBAL.clearTimeout; GLOBAL.clearInterval = GLOBAL.clearTimeout;

Loading…
Cancel
Save