[node:net] Hopefully fix unix sockets

This commit is contained in:
Jarred Sumner
2023-01-11 13:58:25 -08:00
parent 8911c398d9
commit 520ecc21ac

View File

@@ -197,7 +197,10 @@ export const Socket = (function (InternalSocket) {
connect(port, host, connectListener) {
// TODO support IPC sockets
var path;
if (typeof host == "function") {
if (arguments.length === 1 && typeof port === "string") {
path = port;
port = undefined;
} else if (typeof host == "function") {
if (typeof port === "string") {
path = port;
port = undefined;