Socket
Socket
Sign inDemoInstall

sentry-node

Package Overview
Dependencies
Maintainers
2
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sentry-node - npm Package Compare versions

Comparing version 0.1.2 to 0.1.3

26

lib-js/sentry.js
// Generated by CoffeeScript 1.6.3
var Sentry, nodeurl, os, quest, _,
var Sentry, events, nodeurl, os, quest, util, _,
__bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; },
__hasProp = {}.hasOwnProperty,
__extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
__indexOf = [].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; };

@@ -14,3 +16,9 @@

module.exports = Sentry = (function() {
util = require('util');
events = require('events');
module.exports = Sentry = (function(_super) {
__extends(Sentry, _super);
function Sentry(settings) {

@@ -26,3 +34,3 @@ this._send = __bind(this._send, this);

} else if (_(settings).isObject()) {
_(this).defaults(settings);
_(this).extend(settings);
if (_.every(['key', 'secret', 'project_id'], function(prop) {

@@ -95,3 +103,4 @@ return _.has(settings, prop);

Sentry.prototype._send = function(data) {
var options, _ref;
var options, _ref,
_this = this;
if (!this.enabled) {

@@ -107,3 +116,3 @@ return console.log(this.disable_message);

headers: {
'X-Sentry-Auth': "Sentry sentry_version=4, sentry_key=" + this.key + ", sentry_secret=" + this.secret + ", sentry_client=sentry-node/0.1.2"
'X-Sentry-Auth': "Sentry sentry_version=4, sentry_key=" + this.key + ", sentry_secret=" + this.secret + ", sentry_client=sentry-node/0.1.3"
},

@@ -114,3 +123,6 @@ json: data

if ((err != null) || res.statusCode > 299) {
return console.error('Error posting event to Sentry:', err, body);
console.error('Error posting event to Sentry:', err, body);
return _this.emit("error", err);
} else {
return _this.emit("logged");
}

@@ -122,2 +134,2 @@ });

})();
})(events.EventEmitter);
{
"name": "sentry-node",
"version": "0.1.2",
"version": "0.1.3",
"description": "simple Node wrapper around Sentry API",

@@ -5,0 +5,0 @@ "engines": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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