'use client';

import { useSentryUncaughtErrors } from '@akinon/next/hooks';
import PzErrorPage from '@akinon/next/views/error-page';

export default function ErrorPage({
  error,
  reset
}: {
  error: Error & { digest?: string; isServerError?: boolean };
  reset: () => void;
}) {
  // DO NOT REMOVE THIS LINE TO REPORT UNCAUGHT ERRORS TO SENTRY
  useSentryUncaughtErrors(error);

  return <PzErrorPage error={error} reset={reset} />;
}
