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

raven

Package Overview
Dependencies
Maintainers
1
Versions
70
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

raven - npm Package Compare versions

Comparing version 0.2.4 to 0.3.0

lib/transports.js

33

lib/client.js

@@ -6,3 +6,3 @@ var parsers = require('./parsers'),

uuid = require('node-uuid'),
http = {http: require('http'), https: require('https')},
transports = require('./transports'),
node_util = require('util'), // node_util to avoid confusion with "utils"

@@ -72,29 +72,2 @@ events = require('events');

_.sendRemote = function sendRemote(message, headers, cb) {
var self = this;
var options = {
host: self.dsn.host,
path: self.dsn.path + '/api/store/',
headers: headers,
method: 'POST',
port: self.dsn.port
}, req = http[self.dsn.protocol].request(options, function(res){
res.setEncoding('utf8');
res.on('data', function(data) {
// don't care!
});
res.on('end', function(){
if(res.statusCode === 200) {
self.emit('logged');
} else {
self.emit('error');
}
});
});
req.on('error', function(e){
self.emit('error');
});
req.end(message);
};
_.send = function send(kwargs) {

@@ -111,4 +84,4 @@ var self = this;

};
self.sendRemote(message, headers);
transports[self.dsn.protocol].send(self, message, headers);
});

@@ -115,0 +88,0 @@ };

var raven = require('./client'),
crypto = require('crypto'),
fs = require('fs'),
url = require('url');
url = require('url')
transports = require('./transports');

@@ -43,2 +44,8 @@ var protocolMap = {

if(~response.protocol.indexOf('+'))
response.protocol = response.protocol.split('+')[1];
if(!transports.hasOwnProperty(response.protocol))
throw new Error('Invalid transport');
var path = parsed.path.substr(1),

@@ -45,0 +52,0 @@ index = path.lastIndexOf('/');

@@ -5,3 +5,3 @@ {

"keywords": ["raven", "sentry", "python"],
"version": "0.2.4",
"version": "0.3.0",
"repository": "git://github.com/mattrobenolt/raven-node.git",

@@ -26,4 +26,5 @@ "author": "Matt Robenolt <matt@ydekproductions.com>",

"nock": "*",
"glob": "*"
"glob": "*",
"mock-udp": "*"
}
}
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