diff --git a/src/PortalWrapper.js b/src/PortalWrapper.js index b9cf8811..bd3e8d98 100644 --- a/src/PortalWrapper.js +++ b/src/PortalWrapper.js @@ -73,7 +73,7 @@ class PortalWrapper extends React.Component { return document.querySelectorAll(getContainer)[0]; } if (typeof getContainer === 'function') { - return getContainer(); + return getContainer() || document.body; } if ( typeof getContainer === 'object' &&