File tree Expand file tree Collapse file tree
layouts/ProjectLayout/UpgradingState Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -242,8 +242,8 @@ export function useSyncTableEditorStateFromLocalStorageWithUrl({
242242 // Use nextjs useSearchParams to get the latest URL params
243243 const searchParams = useSearchParams ( )
244244 const urlParams = useMemo ( ( ) => {
245- const sort = searchParams . getAll ( 'sort' )
246- const filter = searchParams . getAll ( 'filter' )
245+ const sort = searchParams ? .getAll ( 'sort' ) ?? [ ]
246+ const filter = searchParams ? .getAll ( 'filter' ) ?? [ ]
247247 return { sort, filter }
248248 } , [ searchParams ] )
249249
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ export const UpgradingState = () => {
3636 {
3737 projectRef : ref ,
3838 projectStatus : project ?. status ,
39- trackingId : queryParams . get ( 'trackingId' ) ,
39+ trackingId : queryParams ? .get ( 'trackingId' ) ,
4040 } ,
4141 {
4242 enabled : IS_PLATFORM ,
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ import type { NextPageWithLayout } from 'types'
1212
1313const SqlQuickstarts : NextPageWithLayout = ( ) => {
1414 const router = useRouter ( )
15- const { ref } = useParams < { ref : string } > ( )
15+ const ref = useParams < { ref : string } > ( ) ?. ref
1616 const tabs = useTabsStateSnapshot ( )
1717
1818 useEffect ( ( ) => {
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ import type { NextPageWithLayout } from 'types'
1212
1313const SqlTemplates : NextPageWithLayout = ( ) => {
1414 const router = useRouter ( )
15- const { ref } = useParams < { ref : string } > ( )
15+ const ref = useParams < { ref : string } > ( ) ?. ref
1616 const tabs = useTabsStateSnapshot ( )
1717
1818 useEffect ( ( ) => {
Original file line number Diff line number Diff line change 3636 " **/*.js" ,
3737 " **/*.jsx" ,
3838 " .next/types/**/*.ts" ,
39- " ./../../packages/ui/src/**/*.d.ts"
39+ " ./../../packages/ui/src/**/*.d.ts" ,
40+ " .next/dev/types/**/*.ts"
4041 ],
4142 "exclude" : [" node_modules" , " public/deno/*.ts" ]
4243}
You can’t perform that action at this time.
0 commit comments