Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit e6bfe04

Browse filesBrowse files
committed
net: remove unused var self = this from old code
Removed an unused `var self = this` that is no longer required. PR-URL: #5224 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
1 parent 4f6ad5c commit e6bfe04
Copy full SHA for e6bfe04

File tree

Expand file treeCollapse file tree

1 file changed

+1
-2
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-2
lines changed
Open diff view settings
Collapse file

‎lib/net.js‎

Copy file name to clipboardExpand all lines: lib/net.js
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -277,9 +277,8 @@ function writeAfterFIN(chunk, encoding, cb) {
277277

278278
var er = new Error('This socket has been ended by the other party');
279279
er.code = 'EPIPE';
280-
var self = this;
281280
// TODO: defer error events consistently everywhere, not just the cb
282-
self.emit('error', er);
281+
this.emit('error', er);
283282
if (typeof cb === 'function') {
284283
process.nextTick(cb, er);
285284
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.