Commit c6cbbf92 authored by Juwan Yoo's avatar Juwan Yoo Committed by Joyee Cheung
Browse files

net: allow missing callback for Socket.connect

Arguments of Socket.prototype.connect should be also normalized,
causing error when called without callback.

Changed Socket.prototype.connect's code same as net.connect and added
test.

Fixes: https://github.com/nodejs/node/issues/11761
PR-URL: https://github.com/nodejs/node/pull/11762


Reviewed-By: default avatarSam Roberts <vieuxtech@gmail.com>
Reviewed-By: default avatarJoyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: default avatarMatteo Collina <matteo.collina@gmail.com>
Reviewed-By: default avatarColin Ihrig <cjihrig@gmail.com>
Reviewed-By: default avatarEvan Lucas <evanlucas@me.com>
parent efec14a7
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment