Skip portals when looking for host siblings

A portal is not part of that host tree despite being a child.
This commit is contained in:
Dan Abramov committed 2016-12-09 16:11:35 +00:00
1 parent 3ba8069fef
commit 4596fc48ba
3 files changed
+2 -4

No files matched your search

@@ -152,7 +152,7 @@ module.exports = function<T, P, I, TI, C, CX>(
// If we don't have a child, try the siblings instead.
continue siblings;
}
if (!node.child) {
if (!node.child || node.tag === HostPortal) {
continue siblings;
} else {
node.child.return = node;