assert: fix loose assert with map and set · nodejs/node@82830a8 · GitHub
Skip to content

Commit 82830a8

Browse files
BridgeARtargos
authored andcommitted
assert: fix loose assert with map and set
There was an oversight when checking the possible loose comparisons. This is now fixed by also accepting `''` instead of `0` or `false`. PR-URL: #22145 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
1 parent bc6905b commit 82830a8

2 files changed

Lines changed: 29 additions & 16 deletions

File tree

lib/internal/util/comparisons.js

Lines changed: 21 additions & 12 deletions

test/parallel/test-assert-deep.js

Lines changed: 8 additions & 4 deletions

0 commit comments

Comments
 (0)