Skip to content

Commit

Permalink
assert: remove unneeded condition
Browse files Browse the repository at this point in the history
PR-URL: #11314
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
  • Loading branch information
Trott authored and MylesBorins committed Mar 9, 2017
1 parent 10a497c commit 32b264c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/assert.js
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,8 @@ assert.notStrictEqual = function notStrictEqual(actual, expected, message) {
};

function expectedException(actual, expected) {
if (!actual || !expected) {
// actual is guaranteed to be an Error object, but we need to check expected.
if (!expected) {
return false;
}

Expand Down

0 comments on commit 32b264c

Please sign in to comment.