node-http-error
Advanced tools
Comparing version 1.0.0 to 1.1.0
@@ -10,3 +10,3 @@ var util = require('util'); | ||
if (!(this instanceof HTTPError)) return new HTTPError(status, message); | ||
// Do the argument shuffle. If a status code is given but no message, look up | ||
@@ -26,6 +26,6 @@ // the message from the Node.js HTTP module | ||
Error.captureStackTrace(this, this.constructor); | ||
// Setup error details | ||
this.name = this.constructor.name; | ||
this.status = status || 500; | ||
this.status = this.statusCode = status || 500; | ||
this.message = message || ''; | ||
@@ -41,3 +41,1 @@ util._extend(this, properties); | ||
}; | ||
{ | ||
"name": "node-http-error", | ||
"version": "1.0.0", | ||
"version": "1.1.0", | ||
"description": "Error subclasses for returning HTTP errors", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
44741