Skip to content

Commit

Permalink
test: replace anonymous closure with arrow funct
Browse files Browse the repository at this point in the history
PR-URL: #24439
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
  • Loading branch information
prabusubra authored and codebytere committed Jan 29, 2019
1 parent 4246a40 commit 66c3dca
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/parallel/test-http-server-stale-close.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ if (process.env.NODE_TEST_FORK_PORT) {
req.write('BAM');
req.end();
} else {
const server = http.createServer(function(req, res) {
const server = http.createServer((req, res) => {
res.writeHead(200, { 'Content-Length': '42' });
req.pipe(res);
req.on('close', function() {
req.on('close', () => {
server.close();
res.end();
});
Expand Down

0 comments on commit 66c3dca

Please sign in to comment.