diff --git a/frontend/app/components/Overview/Overview.tsx b/frontend/app/components/Overview/Overview.tsx index 3bb78a4ce..2014ab905 100644 --- a/frontend/app/components/Overview/Overview.tsx +++ b/frontend/app/components/Overview/Overview.tsx @@ -34,7 +34,7 @@ function Overview({ match: { params } }: IProps) {
- +
diff --git a/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js b/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js index d8158f598..d503a33a9 100644 --- a/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js +++ b/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js @@ -4,52 +4,51 @@ import { connect } from 'react-redux'; import { onboarding as onboardingRoute } from 'App/routes'; import { withRouter } from 'react-router-dom'; import * as routes from '../../../routes'; + const withSiteId = routes.withSiteId; const NoSessionsMessage = (props) => { - const { - sites, - match: { - params: { siteId }, - }, - } = props; - const activeSite = sites.find((s) => s.id == siteId); - const showNoSessions = !!activeSite && !activeSite.recorded; - return ( - <> - {showNoSessions && ( -
-
-
-
- -
-
- It might take a few minutes for first recording to appear. - - Troubleshoot - - . -
- -
-
-
- )} - - ); + const { + sites, + siteId + } = props; + const activeSite = sites.find((s) => s.id === siteId); + const showNoSessions = !!activeSite && !activeSite.recorded; + return ( + <> + {showNoSessions && ( +
+
+
+
+ +
+
+ It might take a few minutes for first recording to appear. + + Troubleshoot + + . +
+ +
+
+
+ )} + + ); }; export default connect((state) => ({ - site: state.getIn(['site', 'siteId']), - sites: state.getIn(['site', 'list']), + site: state.getIn(['site', 'siteId']), + sites: state.getIn(['site', 'list']) }))(withRouter(NoSessionsMessage));