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

@pager/hapi-raven

Package Overview
Dependencies
Maintainers
13
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pager/hapi-raven - npm Package Compare versions

Comparing version 6.0.0-hapi17-rc.1 to 6.0.0-hapi17-rc.2

45

lib/index.js

@@ -22,27 +22,34 @@ 'use strict';

server.expose('raven', Raven);
server.events.on('request', (request, err) => {
/* $lab:coverage:off$ */
const baseUrl = request.info.uri ||
server.events.on('request', (request, event, tags) => {
if (event.channel === 'error') {
/* $lab:coverage:off$ */
const baseUrl = request.info.uri ||
request.info.host && `${server.info.protocol}://${request.info.host}` ||
server.info.uri;
/* $lab:coverage:on$ */
/* $lab:coverage:on$ */
Raven.captureException(err, {
request: {
method: request.method,
query_string: request.query,
headers: request.headers,
cookies: request.state,
url: `${baseUrl}${request.path}`
},
extra: {
timestamp: request.info.received,
id: request.id,
remoteAddress: request.info.remoteAddress
},
tags: options.tags
});
Raven.captureException(event.error, {
request: {
method: request.method,
query_string: request.query,
headers: request.headers,
cookies: request.state,
url: `${baseUrl}${request.path}`
},
extra: {
timestamp: request.info.received,
id: event.request,
remoteAddress: request.info.remoteAddress
},
tags: event.tags
});
}
});
}
};
{
"name": "@pager/hapi-raven",
"version": "6.0.0-hapi17-rc.1",
"version": "6.0.0-hapi17-rc.2",
"description": "A Hapi plugin for sending exceptions to Sentry through Raven",

@@ -5,0 +5,0 @@ "main": "./lib",

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