@tryghost/mw-error-handler 0.1.3 → 0.1.4

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.
@@ -173,27 +173,27 @@ module.exports.pageNotFound = (req, res, next) => {
173
173
  };
174
174
 
175
175
  module.exports.handleJSONResponse = sentry => [
176
- // Make sure the error can be served
177
- module.exports.prepareError,
178
176
  // Handle the error in Sentry
179
177
  sentry.errorHandler,
178
+ // Make sure the error can be served
179
+ module.exports.prepareError,
180
180
  // Render the error using JSON format
181
181
  jsonErrorRenderer
182
182
  ];
183
183
 
184
184
  module.exports.handleJSONResponseV2 = sentry => [
185
- // Make sure the error can be served
186
- module.exports.prepareError,
187
185
  // Handle the error in Sentry
188
186
  sentry.errorHandler,
187
+ // Make sure the error can be served
188
+ module.exports.prepareError,
189
189
  // Render the error using JSON format
190
190
  jsonErrorRendererV2
191
191
  ];
192
192
 
193
193
  module.exports.handleHTMLResponse = sentry => [
194
- // Make sure the error can be served
195
- module.exports.prepareError,
196
194
  // Handle the error in Sentry
197
- sentry.errorHandler
195
+ sentry.errorHandler,
196
+ // Make sure the error can be served
197
+ module.exports.prepareError
198
198
  ];
199
199
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tryghost/mw-error-handler",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "repository": "https://github.com/TryGhost/Utils/tree/main/packages/mw-error-handler",
5
5
  "author": "Ghost Foundation",
6
6
  "license": "MIT",
@@ -26,7 +26,9 @@
26
26
  },
27
27
  "dependencies": {
28
28
  "@tryghost/debug": "^0.1.9",
29
- "@tryghost/tpl": "^0.1.8"
29
+ "@tryghost/errors": "1.2.5",
30
+ "@tryghost/tpl": "^0.1.8",
31
+ "lodash": "4.17.21"
30
32
  },
31
- "gitHead": "66b978f9e41829822d5406699b7f67275606e2a2"
33
+ "gitHead": "3bf8b2007541db078debd4d6b4b9f16e66f08c60"
32
34
  }