Skip to content

Commit

Permalink
Revert changes to isSubsetOf
Browse files Browse the repository at this point in the history
  • Loading branch information
koddsson committed Jan 29, 2024
1 parent 6b8c0cd commit 0e2db37
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/chai/core/assertions.js
Original file line number Diff line number Diff line change
Expand Up @@ -3043,9 +3043,7 @@ Assertion.addMethod('closeTo', closeTo);
Assertion.addMethod('approximately', closeTo);

// Note: Duplicates are ignored if testing for inclusion instead of sameness.
function isSubsetOf(_subset, _superset, cmp, contains, ordered) {
let superset = Array.from(_superset);
let subset = Array.from(_subset);
function isSubsetOf(subset, superset, cmp, contains, ordered) {
if (!contains) {
if (subset.length !== superset.length) return false;
superset = superset.slice();
Expand Down

0 comments on commit 0e2db37

Please sign in to comment.