exit with 1 on api error

This commit is contained in:
Chris Wanstrath
2011-02-04 14:49:53 -08:00
parent 58a1b32c3f
commit e09135a577
+1
View File
@@ -71,6 +71,7 @@ request = (method, path, body, callback) ->
response.setEncoding('utf8')
response.on 'data', (chunk) ->
console.log chunk
process.exit(1)
req.write(body) if method is 'POST' and body
req.end()