Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hapi/boom

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hapi/boom - npm Package Compare versions

Comparing version 7.4.4 to 7.4.5

15

lib/index.js

@@ -86,10 +86,11 @@ 'use strict';

error.data = data;
internals.initialize(error, statusCode);
error.typeof = ctor;
const boom = internals.initialize(error, statusCode);
Object.defineProperty(boom, 'typeof', { value: ctor });
if (options.decorate) {
Object.assign(error, options.decorate);
Object.assign(boom, options.decorate);
}
return error;
return boom;
}

@@ -375,3 +376,2 @@

internals.initialize = function (err, statusCode, message) {

@@ -395,3 +395,3 @@

err.reformat = internals.reformat;
Object.defineProperty(err, 'reformat', { value: internals.reformat });

@@ -406,2 +406,5 @@ if (!message &&

if (message) {
const props = Object.getOwnPropertyDescriptor(err, 'message') || Object.getOwnPropertyDescriptor(Object.getPrototypeOf(err), 'message');
Hoek.assert(props.configurable && !props.get, 'The error is not compatible with boom');
err.message = message + (err.message ? ': ' + err.message : '');

@@ -408,0 +411,0 @@ err.output.payload.message = err.message;

2

package.json
{
"name": "@hapi/boom",
"description": "HTTP-friendly error objects",
"version": "7.4.4",
"version": "7.4.5",
"repository": "git://github.com/hapijs/boom",

@@ -6,0 +6,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc