Socket
Socket
Sign inDemoInstall

@sentry/core

Package Overview
Dependencies
Maintainers
8
Versions
526
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sentry/core - npm Package Compare versions

Comparing version 4.0.0-beta.9 to 4.0.0-beta.10

14

dist/base.d.ts
import { Scope } from '@sentry/hub';
import { Breadcrumb, SdkInfo, SentryEvent, SentryResponse } from '@sentry/types';
import { Breadcrumb, SentryEvent, SentryResponse } from '@sentry/types';
import { DSN } from './dsn';

@@ -17,5 +17,2 @@ import { Backend, Client, Options } from './interfaces';

*
* Subclasses must implement one abstract method: {@link getSdkInfo}. It must
* return the unique name and the version of the SDK.
*
* If a DSN is specified in the options, it will be parsed and stored. Use

@@ -99,6 +96,2 @@ * {@link Client.getDSN} to retrieve the DSN at any moment. In case the DSN is

getOptions(): O;
/**
* @inheritDoc
*/
abstract getSdkInfo(): SdkInfo;
/** Returns the current backend. */

@@ -111,4 +104,3 @@ protected getBackend(): B;

*
* The information includes release and environment from `options`, SDK
* information returned by {@link BaseClient.getSdkInfo}, as well as
* The information includes release and environment from `options`,
* breadcrumbs and context (extra, tags and user) from the scope.

@@ -123,3 +115,3 @@ *

*/
protected prepareEvent(event: SentryEvent, scope?: Scope): Promise<SentryEvent>;
protected prepareEvent(event: SentryEvent, scope?: Scope): Promise<SentryEvent | null>;
/**

@@ -126,0 +118,0 @@ * Processes an event (either error or message) and sends it to Sentry.

@@ -72,5 +72,2 @@ "use strict";

*
* Subclasses must implement one abstract method: {@link getSdkInfo}. It must
* return the unique name and the version of the SDK.
*
* If a DSN is specified in the options, it will be parsed and stored. Use

@@ -196,5 +193,3 @@ * {@link Client.getDSN} to retrieve the DSN at any moment. In case the DSN is

}
finalBreadcrumb = beforeBreadcrumb
? beforeBreadcrumb(mergedBreadcrumb)
: mergedBreadcrumb;
finalBreadcrumb = beforeBreadcrumb ? beforeBreadcrumb(mergedBreadcrumb) : mergedBreadcrumb;
return [4 /*yield*/, this.getBackend().storeBreadcrumb(finalBreadcrumb)];

@@ -236,4 +231,3 @@ case 1:

*
* The information includes release and environment from `options`, SDK
* information returned by {@link BaseClient.getSdkInfo}, as well as
* The information includes release and environment from `options`,
* breadcrumbs and context (extra, tags and user) from the scope.

@@ -253,3 +247,3 @@ *

_a = this.getOptions(), environment = _a.environment, _b = _a.maxBreadcrumbs, maxBreadcrumbs = _b === void 0 ? DEFAULT_BREADCRUMBS : _b, release = _a.release;
prepared = __assign({ sdk: this.getSdkInfo() }, event);
prepared = __assign({}, event);
if (prepared.environment === undefined && environment !== undefined) {

@@ -264,5 +258,3 @@ prepared.environment = environment;

}
exception = prepared.exception &&
prepared.exception.values &&
prepared.exception.values[0];
exception = prepared.exception && prepared.exception.values && prepared.exception.values[0];
if (exception && exception.value) {

@@ -310,4 +302,2 @@ exception.value = string_1.truncate(exception.value, MAX_URL_LENGTH);

return [2 /*return*/, {
code: -1,
event_id: event.event_id,
status: types_1.Status.Skipped,

@@ -320,6 +310,4 @@ }];

_a = this.getOptions(), shouldSend = _a.shouldSend, beforeSend = _a.beforeSend, afterSend = _a.afterSend;
if (shouldSend && !shouldSend(prepared)) {
if (prepared === null || (shouldSend && !shouldSend(prepared))) {
return [2 /*return*/, {
code: -1,
event_id: event.event_id,
status: types_1.Status.Skipped,

@@ -326,0 +314,0 @@ }];

@@ -1,2 +0,2 @@

export { captureException, captureMessage, configureScope, } from '@sentry/minimal';
export { captureException, captureMessage, configureScope } from '@sentry/minimal';
export { Hub, Scope } from '@sentry/hub';

@@ -3,0 +3,0 @@ export { BackendClass, BaseClient } from './base';

import { Scope } from '@sentry/hub';
import { Breadcrumb, Integration, SdkInfo, SentryEvent, SentryResponse, Transport, TransportClass, TransportOptions } from '@sentry/types';
import { Breadcrumb, Integration, SentryEvent, SentryResponse, Transport, TransportClass, TransportOptions } from '@sentry/types';
import { DSN } from './dsn';

@@ -186,4 +186,2 @@ /** Console logging verbosity for the SDK. */

getOptions(): O;
/** Returns the current used SDK version and name. */
getSdkInfo(): SdkInfo;
}

@@ -190,0 +188,0 @@ /**

{
"name": "@sentry/core",
"version": "4.0.0-beta.9",
"version": "4.0.0-beta.10",
"description": "Base implementation for all Sentry JavaScript SDKs",

@@ -18,6 +18,6 @@ "repository": "git://github.com/getsentry/raven-js.git",

"dependencies": {
"@sentry/hub": "4.0.0-beta.9",
"@sentry/minimal": "4.0.0-beta.9",
"@sentry/types": "4.0.0-beta.9",
"@sentry/utils": "4.0.0-beta.9"
"@sentry/hub": "4.0.0-beta.10",
"@sentry/minimal": "4.0.0-beta.10",
"@sentry/types": "4.0.0-beta.10",
"@sentry/utils": "4.0.0-beta.10"
},

@@ -24,0 +24,0 @@ "devDependencies": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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