From 069fd2345b00aada316d0dcf385b04fd0247f6f3 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Wed, 6 Dec 2017 10:15:58 -0800 Subject: [PATCH] doc: fix common typo involving one-time listeners Our docs use both "one time listener" and "one-time listener". The second is more correct. Standardize on that. PR-URL: https://github.com/nodejs/node/pull/17502 Reviewed-By: Colin Ihrig Reviewed-By: Richard Lau Reviewed-By: Anatoli Papirovski Reviewed-By: Jon Moss Reviewed-By: Minwoo Jung Reviewed-By: Luigi Pinca --- doc/api/events.md | 4 ++-- doc/api/http.md | 2 +- doc/api/net.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/api/events.md b/doc/api/events.md index 443137f1705e26..8eaa8cae102b75 100644 --- a/doc/api/events.md +++ b/doc/api/events.md @@ -409,7 +409,7 @@ added: v0.3.0 * `eventName` {any} The name of the event. * `listener` {Function} The callback function -Adds a **one time** `listener` function for the event named `eventName`. The +Adds a **one-time** `listener` function for the event named `eventName`. The next time `eventName` is triggered, this listener is removed and then invoked. ```js @@ -464,7 +464,7 @@ added: v6.0.0 * `eventName` {any} The name of the event. * `listener` {Function} The callback function -Adds a **one time** `listener` function for the event named `eventName` to the +Adds a **one-time** `listener` function for the event named `eventName` to the *beginning* of the listeners array. The next time `eventName` is triggered, this listener is removed, and then invoked. diff --git a/doc/api/http.md b/doc/api/http.md index 32876734ae635e..ccc4897399a2d6 100644 --- a/doc/api/http.md +++ b/doc/api/http.md @@ -1782,7 +1782,7 @@ This function allows one to transparently issue requests. string, it is automatically parsed with [`url.parse()`][]. If it is a [`URL`][] object, it will be automatically converted to an ordinary `options` object. -The optional `callback` parameter will be added as a one time listener for +The optional `callback` parameter will be added as a one-time listener for the [`'response'`][] event. `http.request()` returns an instance of the [`http.ClientRequest`][] diff --git a/doc/api/net.md b/doc/api/net.md index ccfdeb5b8495dd..5c1300eb2e42f9 100644 --- a/doc/api/net.md +++ b/doc/api/net.md @@ -802,7 +802,7 @@ socket.on('timeout', () => { If `timeout` is 0, then the existing idle timeout is disabled. -The optional `callback` parameter will be added as a one time listener for the +The optional `callback` parameter will be added as a one-time listener for the [`'timeout'`][] event. ### socket.unref()