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

h2o2

Package Overview
Dependencies
Maintainers
5
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

h2o2 - npm Package Compare versions

Comparing version 7.0.0 to 7.0.1

10

lib/index.js

@@ -149,2 +149,6 @@ 'use strict';

if (settings.onRequest) {
settings.onRequest(promise.req);
}
try {

@@ -155,3 +159,3 @@ res = await promise;

if (settings.onResponse) {
return settings.onResponse.call(bind, error, res, h, settings, ttl);
return settings.onResponse.call(bind, error, res, request, h, settings, ttl);
}

@@ -172,6 +176,2 @@

if (settings.onRequest) {
settings.onRequest(promise.req);
}
if (settings.onResponse) {

@@ -178,0 +178,0 @@ return settings.onResponse.call(bind, null, res, request, h, settings, ttl);

{
"name": "h2o2",
"description": "Proxy handler plugin for hapi.js",
"version": "7.0.0",
"version": "7.0.1",
"repository": "git://github.com/hapijs/h2o2",

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

@@ -495,2 +495,9 @@ 'use strict';

const upstream = Hapi.Server();
let upstreamRequested = false;
upstream.events.on('request', () => {
upstreamRequested = true;
});
await upstream.start();

@@ -502,2 +509,3 @@

called = true;
expect(upstreamRequested).to.be.false();
expect(req).to.be.an.instanceof(Http.ClientRequest);

@@ -673,2 +681,3 @@ };

expect(h.response).to.exist();
throw err;

@@ -675,0 +684,0 @@ };

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