sintaxi/node-dbox — pull request #15 by dannyamey (2012-03-06 12:53:10+00:00)
Title: Return `null` instead of `r.statusCode` if an error occurred

If an error occurs connecting to Dropbox the request library will return an error and no response, causing a fatal error when attempting to access the `statusCode` property. This change will return a `null` value instead of `r.statusCode` from dropbox client methods if an error occurs, allowing the calling application to handle the error more gracefully.

A better solution might be to follow the node callback convention by passing the request error object as the first parameter to callbacks, but as that will break every function signature I've left it alone for now.