diff --git a/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js b/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js index 2dec6fc5d..1a8e271be 100644 --- a/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js +++ b/frontend/app/components/shared/NoSessionsMessage/NoSessionsMessage.js @@ -6,6 +6,7 @@ import { withRouter } from 'react-router-dom'; import * as routes from '../../../routes'; import { indigo } from 'tailwindcss/colors'; import { SquareArrowOutUpRight } from 'lucide-react'; +import { useHistory } from 'react-router'; const withSiteId = routes.withSiteId; @@ -17,6 +18,7 @@ const NoSessionsMessage = (props) => { sites, siteId } = props; + const history = useHistory(); const activeSite = sites.find((s) => s.id === siteId); const showNoSessions = !!activeSite && !activeSite.recorded; const onboardingPath = withSiteId(onboardingRoute('installing'), siteId); @@ -24,35 +26,35 @@ const NoSessionsMessage = (props) => { return ( <> {showNoSessions && ( -