fix: 修复Scene组件容器找不到

This commit is contained in:
聆一 2020-02-22 21:02:04 +08:00
parent 64a2f53cd4
commit 2415c01e84
1 changed files with 2 additions and 2 deletions

View File

@ -25,7 +25,7 @@ export default React.memo((props: IMapSceneConig) => {
};
}, []);
return scene !== null && scene !== undefined ? (
return (
<SceneContext.Provider value={scene}>
{createElement(
'div',
@ -37,5 +37,5 @@ export default React.memo((props: IMapSceneConig) => {
scene && props.children,
)}
</SceneContext.Provider>
) : null;
);
});