From ac0fe1e993299cba9c869c91c25f150dd68fcf04 Mon Sep 17 00:00:00 2001 From: Mihir Samdarshi Date: Wed, 24 Jul 2024 12:05:45 -0700 Subject: [PATCH] fix: fix dashboard auth redirection --- src/App/App.jsx | 4 ++-- src/Auth/callback.jsx | 12 ++++-------- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/App/App.jsx b/src/App/App.jsx index 8fc4998f..bb1776c6 100644 --- a/src/App/App.jsx +++ b/src/App/App.jsx @@ -1,3 +1,4 @@ +import Callback from "@/Auth/callback.jsx"; import React, { lazy, Suspense } from 'react'; import { Provider } from 'react-redux'; import { BrowserRouter, Route, Routes } from 'react-router-dom'; @@ -63,7 +64,6 @@ const ClinicalStudyProtocols = lazy( const Pass1b06PhenotypeAnimalConnected = lazy( () => import('../AnalysisPage/pass1b06PhenotypeAnimal'), ); -const CallbackConnected = lazy(() => import('../Auth/callback')); const store = configureStore(); @@ -82,7 +82,7 @@ function App({ history = History }) { }> } + element={} /> state.auth); const dispatch = useDispatch(); // Handle authentication if expected values are in the URL. @@ -26,10 +28,4 @@ function Callback({ location = { hash: '' } }) { ); } -Callback.propTypes = { - location: PropTypes.shape({ - hash: PropTypes.string, - }), -}; - export default Callback;