From 0d0d7d1ea92f0dd8e95b9894956739c6e751d9b8 Mon Sep 17 00:00:00 2001
From: Hanbyul Jo <hanbyul@nyu.edu>
Date: Thu, 2 Nov 2023 15:27:44 -0400
Subject: [PATCH] Add discoveries redirection back

---
 app/scripts/main.tsx | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/app/scripts/main.tsx b/app/scripts/main.tsx
index 4db0f935d..4b4a7af93 100644
--- a/app/scripts/main.tsx
+++ b/app/scripts/main.tsx
@@ -5,6 +5,7 @@ import { BrowserRouter, Route, Routes, useLocation } from 'react-router-dom';
 import { DevseedUiThemeProvider as DsTp } from '@devseed-ui/theme-provider';
 import { userPages } from 'veda';
 
+import { discoveryRoutes } from './redirects';
 import theme, { GlobalStyles } from '$styles/theme';
 import { getAppURL } from '$utils/history';
 import LayoutRoot, {
@@ -14,7 +15,6 @@ import { useScrollbarWidthAsCssVar } from '$utils/use-scrollbar-width-css';
 
 // Page loading
 import { PageLoading } from '$components/common/loading-skeleton';
-
 // Views
 import UhOh from '$components/uhoh';
 import ErrorBoundary from '$components/uhoh/fatal-error';
@@ -110,6 +110,10 @@ function Root() {
                 {process.env.NODE_ENV !== 'production' && (
                   <Route path='/sandbox/*' element={<Sandbox />} />
                 )}
+
+                {/* Legacy: Routes related to renaming /discoveries to /stories. */}
+                {discoveryRoutes}
+
                 {userPages.map((p) => (
                   <Route
                     key={p}