@sentry/browser 6.14.2 → 6.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/bundle.es6.js +35 -35
- package/build/bundle.es6.js.map +1 -1
- package/build/bundle.es6.min.js +2 -2
- package/build/bundle.es6.min.js.map +1 -1
- package/build/bundle.js +35 -35
- package/build/bundle.js.map +1 -1
- package/build/bundle.min.js +2 -2
- package/build/bundle.min.js.map +1 -1
- package/dist/eventbuilder.d.ts.map +1 -1
- package/dist/eventbuilder.js +19 -10
- package/dist/eventbuilder.js.map +1 -1
- package/esm/eventbuilder.d.ts.map +1 -1
- package/esm/eventbuilder.js +19 -10
- package/esm/eventbuilder.js.map +1 -1
- package/package.json +15 -16
package/build/bundle.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @sentry/browser 6.
|
|
1
|
+
/*! @sentry/browser 6.16.1 (6919d17) | https://github.com/getsentry/sentry-javascript */
|
|
2
2
|
var Sentry = (function (exports) {
|
|
3
3
|
/*! *****************************************************************************
|
|
4
4
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -336,7 +336,7 @@ var Sentry = (function (exports) {
|
|
|
336
336
|
return Object.prototype.toString.call(wat) === '[object DOMException]';
|
|
337
337
|
}
|
|
338
338
|
/**
|
|
339
|
-
* Checks whether
|
|
339
|
+
* Checks whether given value's type is a string
|
|
340
340
|
* {@link isString}.
|
|
341
341
|
*
|
|
342
342
|
* @param wat A value to be checked.
|
|
@@ -1185,9 +1185,10 @@ var Sentry = (function (exports) {
|
|
|
1185
1185
|
* Given any object, return the new object with removed keys that value was `undefined`.
|
|
1186
1186
|
* Works recursively on objects and arrays.
|
|
1187
1187
|
*/
|
|
1188
|
-
function dropUndefinedKeys(
|
|
1188
|
+
function dropUndefinedKeys(val) {
|
|
1189
1189
|
var e_1, _a;
|
|
1190
|
-
if (isPlainObject(
|
|
1190
|
+
if (isPlainObject(val)) {
|
|
1191
|
+
var obj = val;
|
|
1191
1192
|
var rv = {};
|
|
1192
1193
|
try {
|
|
1193
1194
|
for (var _b = __values(Object.keys(obj)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
@@ -1206,10 +1207,10 @@ var Sentry = (function (exports) {
|
|
|
1206
1207
|
}
|
|
1207
1208
|
return rv;
|
|
1208
1209
|
}
|
|
1209
|
-
if (Array.isArray(
|
|
1210
|
-
return
|
|
1210
|
+
if (Array.isArray(val)) {
|
|
1211
|
+
return val.map(dropUndefinedKeys);
|
|
1211
1212
|
}
|
|
1212
|
-
return
|
|
1213
|
+
return val;
|
|
1213
1214
|
}
|
|
1214
1215
|
|
|
1215
1216
|
/**
|
|
@@ -2030,16 +2031,6 @@ var Sentry = (function (exports) {
|
|
|
2030
2031
|
}
|
|
2031
2032
|
|
|
2032
2033
|
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
|
2033
|
-
/** SyncPromise internal states */
|
|
2034
|
-
var States;
|
|
2035
|
-
(function (States) {
|
|
2036
|
-
/** Pending */
|
|
2037
|
-
States["PENDING"] = "PENDING";
|
|
2038
|
-
/** Resolved / OK */
|
|
2039
|
-
States["RESOLVED"] = "RESOLVED";
|
|
2040
|
-
/** Rejected / Error */
|
|
2041
|
-
States["REJECTED"] = "REJECTED";
|
|
2042
|
-
})(States || (States = {}));
|
|
2043
2034
|
/**
|
|
2044
2035
|
* Thenable class that behaves like a Promise and follows it's interface
|
|
2045
2036
|
* but is not async internally
|
|
@@ -2047,19 +2038,19 @@ var Sentry = (function (exports) {
|
|
|
2047
2038
|
var SyncPromise = /** @class */ (function () {
|
|
2048
2039
|
function SyncPromise(executor) {
|
|
2049
2040
|
var _this = this;
|
|
2050
|
-
this._state =
|
|
2041
|
+
this._state = "PENDING" /* PENDING */;
|
|
2051
2042
|
this._handlers = [];
|
|
2052
2043
|
/** JSDoc */
|
|
2053
2044
|
this._resolve = function (value) {
|
|
2054
|
-
_this._setResult(
|
|
2045
|
+
_this._setResult("RESOLVED" /* RESOLVED */, value);
|
|
2055
2046
|
};
|
|
2056
2047
|
/** JSDoc */
|
|
2057
2048
|
this._reject = function (reason) {
|
|
2058
|
-
_this._setResult(
|
|
2049
|
+
_this._setResult("REJECTED" /* REJECTED */, reason);
|
|
2059
2050
|
};
|
|
2060
2051
|
/** JSDoc */
|
|
2061
2052
|
this._setResult = function (state, value) {
|
|
2062
|
-
if (_this._state !==
|
|
2053
|
+
if (_this._state !== "PENDING" /* PENDING */) {
|
|
2063
2054
|
return;
|
|
2064
2055
|
}
|
|
2065
2056
|
if (isThenable(value)) {
|
|
@@ -2078,7 +2069,7 @@ var Sentry = (function (exports) {
|
|
|
2078
2069
|
};
|
|
2079
2070
|
/** JSDoc */
|
|
2080
2071
|
this._executeHandlers = function () {
|
|
2081
|
-
if (_this._state ===
|
|
2072
|
+
if (_this._state === "PENDING" /* PENDING */) {
|
|
2082
2073
|
return;
|
|
2083
2074
|
}
|
|
2084
2075
|
var cachedHandlers = _this._handlers.slice();
|
|
@@ -2087,13 +2078,13 @@ var Sentry = (function (exports) {
|
|
|
2087
2078
|
if (handler.done) {
|
|
2088
2079
|
return;
|
|
2089
2080
|
}
|
|
2090
|
-
if (_this._state ===
|
|
2081
|
+
if (_this._state === "RESOLVED" /* RESOLVED */) {
|
|
2091
2082
|
if (handler.onfulfilled) {
|
|
2092
2083
|
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
|
2093
2084
|
handler.onfulfilled(_this._value);
|
|
2094
2085
|
}
|
|
2095
2086
|
}
|
|
2096
|
-
if (_this._state ===
|
|
2087
|
+
if (_this._state === "REJECTED" /* REJECTED */) {
|
|
2097
2088
|
if (handler.onrejected) {
|
|
2098
2089
|
handler.onrejected(_this._value);
|
|
2099
2090
|
}
|
|
@@ -4557,7 +4548,7 @@ var Sentry = (function (exports) {
|
|
|
4557
4548
|
hub.bindClient(client);
|
|
4558
4549
|
}
|
|
4559
4550
|
|
|
4560
|
-
var SDK_VERSION = '6.
|
|
4551
|
+
var SDK_VERSION = '6.16.1';
|
|
4561
4552
|
|
|
4562
4553
|
var originalFunctionToString;
|
|
4563
4554
|
/** Patch toString calls to return proper name for wrapped functions */
|
|
@@ -5150,23 +5141,32 @@ var Sentry = (function (exports) {
|
|
|
5150
5141
|
function eventFromUnknownInput(exception, syntheticException, options) {
|
|
5151
5142
|
if (options === void 0) { options = {}; }
|
|
5152
5143
|
var event;
|
|
5153
|
-
if (isErrorEvent(exception)) {
|
|
5144
|
+
if (isErrorEvent(exception) && exception.error) {
|
|
5154
5145
|
// If it is an ErrorEvent with `error` property, extract it to get actual Error
|
|
5146
|
+
var errorEvent = exception;
|
|
5155
5147
|
// eslint-disable-next-line no-param-reassign
|
|
5156
|
-
exception =
|
|
5148
|
+
exception = errorEvent.error;
|
|
5157
5149
|
event = eventFromStacktrace(computeStackTrace(exception));
|
|
5158
5150
|
return event;
|
|
5159
5151
|
}
|
|
5152
|
+
// If it is a `DOMError` (which is a legacy API, but still supported in some browsers) then we just extract the name
|
|
5153
|
+
// and message, as it doesn't provide anything else. According to the spec, all `DOMExceptions` should also be
|
|
5154
|
+
// `Error`s, but that's not the case in IE11, so in that case we treat it the same as we do a `DOMError`.
|
|
5155
|
+
//
|
|
5156
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/DOMError
|
|
5157
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/DOMException
|
|
5158
|
+
// https://webidl.spec.whatwg.org/#es-DOMException-specialness
|
|
5160
5159
|
if (isDOMError(exception) || isDOMException(exception)) {
|
|
5161
|
-
// If it is a DOMError or DOMException (which are legacy APIs, but still supported in some browsers)
|
|
5162
|
-
// then we just extract the name, code, and message, as they don't provide anything else
|
|
5163
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/DOMError
|
|
5164
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/DOMException
|
|
5165
5160
|
var domException = exception;
|
|
5166
|
-
|
|
5167
|
-
|
|
5168
|
-
|
|
5169
|
-
|
|
5161
|
+
if ('stack' in exception) {
|
|
5162
|
+
event = eventFromStacktrace(computeStackTrace(exception));
|
|
5163
|
+
}
|
|
5164
|
+
else {
|
|
5165
|
+
var name_1 = domException.name || (isDOMError(domException) ? 'DOMError' : 'DOMException');
|
|
5166
|
+
var message = domException.message ? name_1 + ": " + domException.message : name_1;
|
|
5167
|
+
event = eventFromString(message, syntheticException, options);
|
|
5168
|
+
addExceptionTypeValue(event, message);
|
|
5169
|
+
}
|
|
5170
5170
|
if ('code' in domException) {
|
|
5171
5171
|
event.tags = __assign(__assign({}, event.tags), { 'DOMException.code': "" + domException.code });
|
|
5172
5172
|
}
|