diff --git a/frontend/app/components/Session/Session.js b/frontend/app/components/Session/Session.js index f7e93c493..c86d7d3e4 100644 --- a/frontend/app/components/Session/Session.js +++ b/frontend/app/components/Session/Session.js @@ -1,5 +1,5 @@ import React from 'react'; -import { useEffect } from 'react'; +import { useEffect, useState } from 'react'; import { connect } from 'react-redux'; import usePageTitle from 'App/hooks/usePageTitle'; import { fetch as fetchSession } from 'Duck/sessions'; @@ -21,18 +21,14 @@ function Session({ fetchSlackList, }) { usePageTitle("OpenReplay Session Player"); - // useEffect(() => { - // fetchSlackList() - // }, []); + const [ initializing, setInitializing ] = useState(true) useEffect(() => { if (sessionId != null) { fetchSession(sessionId) } else { console.error("No sessionID in route.") } - return () => { - if (!session.exists()) return; - } + setInitializing(false) },[ sessionId ]); return ( @@ -46,7 +42,7 @@ function Session({ } > - + { session.isIOS ? :