Created
August 6, 2012 16:15
-
-
Save heapwolf/3276024 to your computer and use it in GitHub Desktop.
emitters/remove
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var req = http.request(options); | |
var responseListener = function(response) { | |
response.on("data", function(data) { | |
console.log("some data from the response", data); | |
}); | |
} | |
req.on('response', responseListener); | |
setTimeout(function() { | |
req.removeListener('response', responseListener); | |
}, 1000); | |
req.end(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment