mirror of
https://github.com/QuivrHQ/quivr.git
synced 2024-12-15 01:21:48 +03:00
fix(sentry): Refactor GlobalError component to use arrow function syntax (#2252)
This pull request refactors the GlobalError component to use arrow function syntax, improving code readability and maintainability.
This commit is contained in:
parent
1b6896f8ca
commit
e95b965fe8
@ -4,7 +4,7 @@ import * as Sentry from "@sentry/nextjs";
|
||||
import Error from "next/error";
|
||||
import { useEffect } from "react";
|
||||
|
||||
export default function GlobalError({ error }) {
|
||||
const GlobalError = ({ error }) => {
|
||||
useEffect(() => {
|
||||
Sentry.captureException(error);
|
||||
}, [error]);
|
||||
@ -16,4 +16,6 @@ export default function GlobalError({ error }) {
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
export default GlobalError;
|
||||
|
Loading…
Reference in New Issue
Block a user