Skip to content

Commit 45761bc

Browse files
authored
fix(react): Remove unnecessary null in FallbackRender's error type (#2893)
We already know `error` exists because of the `if (error)` check. Fixes #2892.
1 parent ca3b6d1 commit 45761bc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/react/src/errorboundary.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ import * as React from 'react';
44

55
export const UNKNOWN_COMPONENT = 'unknown';
66

7-
export type FallbackRender = (fallback: {
8-
error: Error | null;
7+
export type FallbackRender = (errorData: {
8+
error: Error;
99
componentStack: string | null;
1010
eventId: string | null;
1111
resetError(): void;

0 commit comments

Comments
 (0)