mcavage/node-restify — pull request #87 by thisandagain (2012-02-29 19:46:01+00:00)
Title: Add detection for and automatic casting for port numbers passed as strings

While testing restify.js on a Joyent SmartMachine I noticed that the standard convention of starting a server by passing:

```javascript
var port = process.env.PORT || 8080;
server.listen(port, function () {
log.info('Server listening on port %s', server.url);
});
````

was not working as expected (Restify.js throws a TypeError) as many environments (Node.js SmartMachines & Heroku included) pass process.env.PORT as a string.