Skip to content

Commit

Permalink
Fix "TypeError: Cannot destructure property 'message' of 'error' as i…
Browse files Browse the repository at this point in the history
…t is undefined."
  • Loading branch information
Vadorequest committed Jun 3, 2020
1 parent ae1bf31 commit c571f31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/errors/ErrorDebug.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ type Props = {
*/
const ErrorDebug = (props: Props): JSX.Element => {
const { error, context }: Props = props;
const { message, stack } = error;
const { message, stack } = error || {};

let stringifiedContext;
try {
Expand Down

0 comments on commit c571f31

Please sign in to comment.