The code I'm looking for does not have "require (" event ")" anywhere ", and yet I see this code
server.on('error', function (e) { if (e.code == 'EADDRINUSE') { console.log('Address in use, retrying...'); setTimeout(function () {
Uses "on".
And looking at this line
var net = require('net')
and this line
var server = net.createServer();
makes me think that the execution of require ('net') already includes the execution of require ('event').
Is it correct?
source share