Skip to content

Commit

Permalink
[expect] optimize compare nodes 🎨
Browse files Browse the repository at this point in the history
  • Loading branch information
Connormiha committed Apr 26, 2019
1 parent 8b6464d commit 043092c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions packages/expect/src/jasmineUtils.ts
Expand Up @@ -127,9 +127,8 @@ function eq(
}

var aIsDomNode = isDomNode(a);
var bIsDomNode = isDomNode(b);
// Use DOM3 method isEqualNode (IE>=9)
if (aIsDomNode && typeof a.isEqualNode === 'function' && bIsDomNode) {
if (aIsDomNode && isDomNode(b)) {
return a.isEqualNode(b);
}

Expand Down

0 comments on commit 043092c

Please sign in to comment.