Skip to content

Commit

Permalink
fix(TooltipPopoverWrapper): replacing find with filter to preve… (#1776)
Browse files Browse the repository at this point in the history
* feat(TooltipPopoverWrapper): replacing find with filter to prevent console error in IE 11

* chore(TooltipPopoverWrapper): undoing formatting from prettier

Fixes #1774
  • Loading branch information
stranzhay committed Jan 31, 2020
1 parent f3ac417 commit 54648b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/TooltipPopoverWrapper.js
Expand Up @@ -62,7 +62,7 @@ function isInDOMSubtree(element, subtreeRoot) {
}

function isInDOMSubtrees(element, subtreeRoots = []) {
return subtreeRoots && subtreeRoots.length && subtreeRoots.find(subTreeRoot=> isInDOMSubtree(element, subTreeRoot));
return subtreeRoots && subtreeRoots.length && subtreeRoots.filter(subTreeRoot=> isInDOMSubtree(element, subTreeRoot))[0];
}

class TooltipPopoverWrapper extends React.Component {
Expand Down

0 comments on commit 54648b6

Please sign in to comment.