summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLance Ball <lball@redhat.com>2017-11-21 14:51:41 -0500
committerLance Ball <lball@redhat.com>2017-11-22 10:28:23 -0500
commit571ecd1aed3a1f04c2910bcf72585506621bb256 (patch)
tree1518cb11f90e4fa4a332bf874e9239ecb7b630fd
parentd7b0c237fb0c9d42ab869cc5d0d549fe7fc95a62 (diff)
downloadandroid-node-v8-571ecd1aed3a1f04c2910bcf72585506621bb256.tar.gz
android-node-v8-571ecd1aed3a1f04c2910bcf72585506621bb256.tar.bz2
android-node-v8-571ecd1aed3a1f04c2910bcf72585506621bb256.zip
test: use arrow function instead of bind
Using an arrow function here eliminates the need to call `bind()`. PR-URL: https://github.com/nodejs/node/pull/17202 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
-rw-r--r--test/parallel/test-https-truncate.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/parallel/test-https-truncate.js b/test/parallel/test-https-truncate.js
index d2a3179c0d..30a869c070 100644
--- a/test/parallel/test-https-truncate.js
+++ b/test/parallel/test-https-truncate.js
@@ -67,6 +67,6 @@ const test = common.mustCall(function(res) {
res.on('data', function(chunk) {
bytes += chunk.length;
this.pause();
- setTimeout(this.resume.bind(this), 1);
+ setTimeout(() => { this.resume() }, 1);
});
});