Skip to content

Commit 6bd5c9d

Browse files
EtanHeyclaude
andcommitted
fix: remove unused browser-only PromiseRejectionEvent handler in test
The handler variable using PromiseRejectionEvent was dead code — the test already uses the Node.js process.on('unhandledRejection') handler. Removing it fixes the TS2304 type error in CI. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 7c943bd commit 6bd5c9d

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

packages/core/test/shared/protocol.test.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -238,12 +238,6 @@ describe('protocol tests', () => {
238238

239239
// Track unhandled rejections
240240
const unhandledRejections: unknown[] = [];
241-
const handler = (event: PromiseRejectionEvent) => {
242-
unhandledRejections.push(event.reason);
243-
event.preventDefault();
244-
};
245-
246-
// In Node.js, listen on process instead of globalThis
247241
const processHandler = (reason: unknown) => {
248242
unhandledRejections.push(reason);
249243
};

0 commit comments

Comments
 (0)