File tree 1 file changed +2
-11
lines changed
1 file changed +2
-11
lines changed Original file line number Diff line number Diff line change 1
- import { createFileRoute , redirect } from '@tanstack/react-router' ;
1
+ import { createFileRoute } from '@tanstack/react-router' ;
2
2
import { useTranslation } from '@i18next-toolkit/react' ;
3
3
import { CommonWrapper } from '@/components/CommonWrapper' ;
4
4
import { routeAuthBeforeLoad } from '@/utils/route' ;
@@ -12,7 +12,6 @@ import {
12
12
} from '@/components/ui/resizable' ;
13
13
import { cn } from '@/utils/style' ;
14
14
import { MetricsSection } from '@/components/insights/MetricsSection' ;
15
- import { isDev } from '@/utils/env' ;
16
15
import {
17
16
Select ,
18
17
SelectContent ,
@@ -31,15 +30,7 @@ import { useEvent } from '@/hooks/useEvent';
31
30
import { BreakdownSection } from '@/components/insights/BreakdownSection' ;
32
31
33
32
export const Route = createFileRoute ( '/insights' ) ( {
34
- beforeLoad : ( opts ) => {
35
- if ( ! isDev ) {
36
- throw redirect ( {
37
- to : '/' ,
38
- } ) ;
39
- }
40
-
41
- return routeAuthBeforeLoad ?.( opts ) ;
42
- } ,
33
+ beforeLoad : routeAuthBeforeLoad ,
43
34
component : PageComponent ,
44
35
} ) ;
45
36
You can’t perform that action at this time.
0 commit comments