@openaddresses/batch-schema 2.3.1 → 2.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -10,6 +10,11 @@
10
10
 
11
11
  ## Version History
12
12
 
13
+ ### v2.3.2
14
+
15
+ - :bug: Fix a status code error handling bug which would crash express
16
+ - :arrow_Up: Update Base Deps
17
+
13
18
  ### v2.3.1
14
19
 
15
20
  - :arrow_up: Update Base Deps
package/lib/error.js CHANGED
@@ -25,7 +25,7 @@ class PublicError {
25
25
 
26
26
  // Duplicate Express supported Error extensions
27
27
  } else if (err instanceof Error && (err.status || err.statusCode)) {
28
- res.status(err.status).json({
28
+ res.status(err.status || err.statusCode).json({
29
29
  status: err.status || err.statusCode,
30
30
  message: err.message || 'Generic Error',
31
31
  messages: messages
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@openaddresses/batch-schema",
3
3
  "root": true,
4
- "version": "2.3.1",
4
+ "version": "2.3.2",
5
5
  "description": "Strongly Validated JSON Schema support for address",
6
6
  "repository": "git@github.com:openaddresses/batch",
7
7
  "author": "ingalls <nick@ingalls.ca>",