Skip to content

Commit

Permalink
fix trying to log the stack of an undefined error
Browse files Browse the repository at this point in the history
we're receiving reports for calls of the uncaught error handler
where the error is undefined from safari users.

moving the log into the try to get a log message with a stack instead
of another uncaught error when this happens.

close #4932
  • Loading branch information
ganthern committed Jan 16, 2023
1 parent a9494d7 commit 6905206
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/misc/ErrorHandler.ts
Expand Up @@ -45,9 +45,8 @@ export async function handleUncaughtError(e: Error) {
throw e
}

console.log("error", e, e.stack)

try {
console.log("error", e, e.stack)
const { handleUncaughtErrorImpl } = await importErrorHandler()
await handleUncaughtErrorImpl(e)
} catch (e) {
Expand Down

0 comments on commit 6905206

Please sign in to comment.