Skip to content

Commit deb1bc2

Browse files
authored
fix: remove event-catcher code (#7898)
1 parent c5c8502 commit deb1bc2

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

packages/browser/src/client/public/error-catcher.js

+1-14
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { channel, client } from '@vitest/browser/client'
1+
import { client } from '@vitest/browser/client'
22

33
function serializeError(unhandledError) {
44
const state = globalThis.__vitest_worker__
@@ -69,19 +69,6 @@ async function reportUnexpectedError(
6969
await client.waitForConnection().then(() => {
7070
return client.rpc.onUnhandledError(processedError, type)
7171
}).catch(console.error)
72-
const state = __vitest_browser_runner__
73-
74-
if (state.type === 'orchestrator') {
75-
return
76-
}
77-
78-
if (!state.runTests || !__vitest_worker__.current) {
79-
channel.postMessage({
80-
// TODO: what to do in this case now?
81-
event: 'response:???',
82-
iframeId: state.iframeId,
83-
})
84-
}
8572
}
8673

8774
registerUnexpectedErrors()

0 commit comments

Comments
 (0)