From 5ec60f21b926563c1f9a0bac251a6d9103d76797 Mon Sep 17 00:00:00 2001 From: Kakhaber Date: Sun, 18 Nov 2018 12:36:21 +0400 Subject: [PATCH] Is node shadow root check improved (#5828) --- src/core/core.helpers.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/core.helpers.js b/src/core/core.helpers.js index d8175af50c5..4b0a18c1648 100644 --- a/src/core/core.helpers.js +++ b/src/core/core.helpers.js @@ -506,7 +506,7 @@ module.exports = function() { */ helpers._getParentNode = function(domNode) { var parent = domNode.parentNode; - if (parent && parent.host) { + if (parent && parent.toString() === '[object ShadowRoot]') { parent = parent.host; } return parent;