Answer the question
In order to leave comments, you need to log in
Why is Event end throwing an error?
Here is the script and the error
var myserver = require('http').createServer().listen(8080);
myserver.on('request', function(x, y){
y.write("1");
x.on('data', function(z){
console.log(z.toString());
//process.stdout.write(msg.toString());
});
x.on('end', function(){
y.end();
});
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question