Skip to content

Commit

Permalink
Rename Error Component
Browse files Browse the repository at this point in the history
  • Loading branch information
pahans committed May 21, 2024
1 parent 2181be7 commit 18f7297
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 30 deletions.
27 changes: 0 additions & 27 deletions src/app/admin/error.tsx

This file was deleted.

8 changes: 5 additions & 3 deletions src/app/error.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
import { Button } from "@/components/ui/button";
import { useEffect } from "react";

export default function Error({
const ErrorPage = ({
error,
reset,
}: {
error: Error & { digest?: string };
reset: () => void;
}) {
}) => {
useEffect(() => {
// Optionally log the error to an error reporting service
console.error(error);
Expand All @@ -23,4 +23,6 @@ export default function Error({
</Button>
</main>
);
}
};

export default ErrorPage;

0 comments on commit 18f7297

Please sign in to comment.