Skip to content

Commit

Permalink
fix: correctly consume ws package
Browse files Browse the repository at this point in the history
  • Loading branch information
benmccann authored Oct 31, 2024
1 parent 91e1c8b commit f314475
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/engine.io-client/lib/transports/websocket.node.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { WebSocket } from "ws";
import * as ws from "ws";
import type { Packet, RawData } from "engine.io-parser";
import { BaseWS } from "./websocket.js";

Expand Down Expand Up @@ -27,7 +27,7 @@ export class WS extends BaseWS {
opts.headers.cookie.push(`${name}=${cookie.value}`);
}
}
return new WebSocket(uri, protocols, opts);
return new ws.WebSocket(uri, protocols, opts);
}

doWrite(packet: Packet, data: RawData) {
Expand Down

0 comments on commit f314475

Please sign in to comment.