mongodb/node-mongodb-native — pull request #815 by aheckmann (2012-12-18 21:01:25+00:00)
Title: fixed; domain sockets shouldn't require a port arg

An undefined port is now accepted which makes using domain sockets simpler for libraries that wrap the driver.

```js
var host = userSpecifiedHost;
var port = userSpecifiedPort;
var options = someOptions;
new Sever(host, port, options) // no need to dig in the driver codebase to figure out how to get domain sockets working anymore :)
```

previous behavior:

```js
new Db(MONGODB, new Server("/tmp/mongodb-27017.sock", undefined, {})).open(callback)

// host and port must be specified [/tmp/mongodb-27017.sock:undefined]
```

now it "just works".

Also stopped throwing strings around and `instanceof Error === true`.