GeezerVison is showing github.com — http,tls: name anonymous callbacks · nodejs/node@1ca46ab
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: lib/_http_outgoing.js +2-2Lines changed: 2 additions & 2 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -183,7 +183,7 @@ OutgoingMessage.prototype.setTimeout = function setTimeout(msecs, callback) { |
183 | 183 | } |
184 | 184 |
|
185 | 185 | if (!this.socket) { |
186 | | - this.once('socket', function(socket) { |
| 186 | + this.once('socket', function socketSetTimeoutOnConnect(socket) { |
187 | 187 | socket.setTimeout(msecs); |
188 | 188 | }); |
189 | 189 | } else { |
@@ -200,7 +200,7 @@ OutgoingMessage.prototype.destroy = function destroy(error) { |
200 | 200 | if (this.socket) { |
201 | 201 | this.socket.destroy(error); |
202 | 202 | } else { |
203 | | - this.once('socket', function(socket) { |
| 203 | + this.once('socket', function socketDestroyOnConnect(socket) { |
204 | 204 | socket.destroy(error); |
205 | 205 | }); |
206 | 206 | } |
|
Collapse file
Copy file name to clipboardExpand all lines: lib/_tls_common.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -240,7 +240,7 @@ exports.translatePeerCertificate = function translatePeerCertificate(c) { |
240 | 240 | c.infoAccess = Object.create(null); |
241 | 241 |
|
242 | 242 | // XXX: More key validation? |
243 | | - info.replace(/([^\n:]*):([^\n]*)(?:\n|$)/g, function(all, key, val) { |
| 243 | + info.replace(/([^\n:]*):([^\n]*)(?:\n|$)/g, (all, key, val) => { |
244 | 244 | if (key in c.infoAccess) |
245 | 245 | c.infoAccess[key].push(val); |
246 | 246 | else |
|