import * as React from 'react' ; import { redirect } from 'remix' ; import type { KCDHandle , KCDLoader } from '~/types' ; import { getEpisodes } from '~/utils/transistor.server' ; import { getEpisodeFromParams , getEpisodePath , Params } from '~/utils/call-kent' ; export const handle = { getSitemapEntries : ( ) => null , } ; export const loader = async ( { params , request } ) => { const episodes = await getEpisodes ( { request } ) ; const episode = getEpisodeFromParams ( episodes , params ) ; if ( ! episode ) { return redirect ( '/calls' ) ; } return redirect ( getEpisodePath ( episode ) ) ; } ; export default function Screen ( ) { return < div > You should have been redirected ... Weird < /div>; }