doc: replace anonymous function with arrow function

PR-URL: https://github.com/nodejs/node/pull/24617
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Yuta Hiroto <hello@hiroppy.me>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
pull/24524/head
ka2jun8 2018-11-24 16:40:56 +09:00 committed by Vse Mozhet Byt
parent 85aa53a1c9
commit 9fe02af794
1 changed files with 3 additions and 3 deletions

View File

@ -444,14 +444,14 @@ function main(conf) {
const http = require('http');
const len = conf.kb * 1024;
const chunk = Buffer.alloc(len, 'x');
const server = http.createServer(function(req, res) {
const server = http.createServer((req, res) => {
res.end(chunk);
});
server.listen(common.PORT, function() {
server.listen(common.PORT, () => {
bench.http({
connections: conf.connections,
}, function() {
}, () => {
server.close();
});
});