Skip to content

Commit

Permalink
refactor: more secure condition
Browse files Browse the repository at this point in the history
  • Loading branch information
kyuwoo.choi committed Jun 28, 2018
1 parent 09c56da commit 7c0b1d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/js/wwTableManager.js
Expand Up @@ -498,7 +498,7 @@ class WwTableManager {
anchorElement = domUtils.getParentUntilBy(startContainer, node => {
return node.tagName === 'TD' || node.tagName === 'TH';
}, node => {
return node.tagName === 'DIV';
return $(node).closest('table').length === 0;
});
anchorElement = anchorElement ? anchorElement.parentNode : null;
}
Expand Down

0 comments on commit 7c0b1d8

Please sign in to comment.