Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Added @jasnell feedbacks
  • Loading branch information
lucamaraschi committed Mar 16, 2017
commit 1177ae7d77510cfab0fb35b66e63ab232a7293f1
8 changes: 4 additions & 4 deletions test/parallel/test-net-options-lookup.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ const net = require('net');

const expectedError = /^TypeError: "lookup" option should be a function$/;

['foobar', 1, {}, []].forEach((input => { connectThrows(input); }))
['foobar', 1, {}, []].forEach((input => connectThrows(input) ));
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can the extra parens around the arrow function here and on line 22 be removed?


function connectThrows(input) {
var opts = {
const opts = {
host: 'localhost',
port: common.PORT,
lookup: input,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you should remove the comma here. Is this passing make lint?

Expand All @@ -19,10 +19,10 @@ function connectThrows(input) {
}, expectedError);
}

[() => {}].forEach((input => { connectDoesNotThrow(input); }))
[() => {}].forEach((input => connectDoesNotThrow(input) ));

function connectDoesNotThrow(input) {
var opts = {
const opts = {
host: 'localhost',
port: common.PORT,
lookup: input,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

Expand Down