Skip to content

Commit

Permalink
fix(node): Do not assert in vendored proxy code (v7 backport) (#11009)
Browse files Browse the repository at this point in the history
  • Loading branch information
timfish authored Mar 11, 2024
1 parent 3fe6106 commit df6f048
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions packages/node/src/proxy/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@

/* eslint-disable @typescript-eslint/explicit-member-accessibility */
/* eslint-disable @typescript-eslint/no-unused-vars */
import assert from 'assert';
import type * as http from 'http';
import type { OutgoingHttpHeaders } from 'http';
import * as net from 'net';
Expand Down Expand Up @@ -190,8 +189,6 @@ export class HttpsProxyAgent<Uri extends string> extends Agent {
// Need to wait for the "socket" event to re-play the "data" events.
req.once('socket', (s: net.Socket) => {
debug('Replaying proxy buffer for failed request');
assert(s.listenerCount('data') > 0);

// Replay the "buffered" Buffer onto the fake `socket`, since at
// this point the HTTP module machinery has been hooked up for
// the user.
Expand Down

0 comments on commit df6f048

Please sign in to comment.