소스 검색

fix globalEmitter initialization

Yuki Takei 3 년 전
부모
커밋
c3b7d79c35
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      packages/app/src/pages/[[...path]].page.tsx

+ 1 - 1
packages/app/src/pages/[[...path]].page.tsx

@@ -189,7 +189,7 @@ const GrowiPage: NextPage<Props> = (props: Props) => {
   const { data: currentUser } = useCurrentUser(props.currentUser ?? null);
 
   // register global EventEmitter
-  if (isClient()) {
+  if (isClient() && window.globalEmitter == null) {
     window.globalEmitter = new EventEmitter();
   }