New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

proxy-gremlin

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

proxy-gremlin - npm Package Compare versions

Comparing version 0.2.1 to 0.2.2

14

index.js

@@ -58,17 +58,16 @@ var util = require('util')

exports.intercept = function(res, interceptor) {
exports.intercept = function intercept(res, interceptor) {
// save the original response method
// Save the original response method;
// buffer will monkey patch the response.
var end = res.end
, writeHead = res.writeHead
, buffer = new Buffer(res)
// Buffer monkey patches the response
var buffer = new Buffer(res)
res.on('end', function onResEnd() {
// apply outgoing transformations on the buffered response
// Apply outgoing transformations on the buffered response.
interceptor(buffer)
// send the response to the client
// Send the response to the client.
writeHead.call(res, buffer.statusCode, buffer.headers)

@@ -78,1 +77,2 @@ end.call(res, buffer.getData(), buffer.encoding)

}
{
"name": "proxy-gremlin",
"version": "0.2.1",
"version": "0.2.2",
"author": "omphalos",

@@ -5,0 +5,0 @@ "description": "Utility to assist in changing proxied requests.",

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