import { addYearMonth } from '@/app/lib/actions/yearMonthActions';
import { revalidatePath } from 'next/cache';
import { redirect } from 'next/navigation';

export default async function Page({ params:{ id } }: { params: { id:string } }) {

    await addYearMonth(id);

    revalidatePath('/');
    redirect(`/`);
}