Skip to content

Conversation

@Flarna
Copy link
Member

@FlarnaFlarna commented Jan 11, 2020

Remove unreachable code. As expected is converted to an Array the 'not ' check will be never executed.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

@nodejs-github-botnodejs-github-bot added the errors Issues and PRs related to JavaScript errors originated in Node.js core. label Jan 11, 2020
Remove unreachable code. As expected is converted to an Array the 'not ' check will be never executed.
@FlarnaFlarnaforce-pushed the errors-remove-dead-code branch from 567229e to 91e2ce2CompareJanuary 11, 2020 22:30
@FlarnaFlarna changed the title lib: remove dead code in ERR_INVALID_ARG_TYPEerrors: remove dead code in ERR_INVALID_ARG_TYPEJan 11, 2020
@BridgeARBridgeAR added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Jan 11, 2020
@nodejs-github-bot
Copy link
Collaborator

}else{
msg+='must be ';
}
msg+='must be ';
Copy link
Contributor

Choose a reason for hiding this comment

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

Could simplify this further by including the literal inline inside the two conditionals above.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

I'm not that a big fan of duplication.

@Trott
Copy link
Member

Landed in eb5e1dd

@TrottTrott closed this Jan 14, 2020
Trott pushed a commit that referenced this pull request Jan 14, 2020
Remove unreachable code. As expected is converted to an Array the 'not ' check will be never executed. PR-URL: #31322 Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Yongsheng Zhang <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rich Trott <[email protected]>
@FlarnaFlarna deleted the errors-remove-dead-code branch January 14, 2020 06:29
MylesBorins pushed a commit that referenced this pull request Jan 16, 2020
Remove unreachable code. As expected is converted to an Array the 'not ' check will be never executed. PR-URL: #31322 Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Yongsheng Zhang <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rich Trott <[email protected]>
@codebyterecodebytere mentioned this pull request Jan 16, 2020
codebytere pushed a commit that referenced this pull request Mar 14, 2020
Remove unreachable code. As expected is converted to an Array the 'not ' check will be never executed. PR-URL: #31322 Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Yongsheng Zhang <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rich Trott <[email protected]>
codebytere pushed a commit that referenced this pull request Mar 17, 2020
Remove unreachable code. As expected is converted to an Array the 'not ' check will be never executed. PR-URL: #31322 Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Yongsheng Zhang <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rich Trott <[email protected]>
@codebyterecodebytere mentioned this pull request Mar 17, 2020
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author readyPRs that have at least one approval, no pending requests for changes, and a CI started.errorsIssues and PRs related to JavaScript errors originated in Node.js core.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants

@Flarna@nodejs-github-bot@Trott@mscdex@lpinca@cjihrig@BridgeAR@ZYSzys