stream-chat 4.4.1 → 4.4.2

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/dist/browser.js CHANGED
@@ -3444,7 +3444,6 @@ var ClientState = /*#__PURE__*/function () {
3444
3444
  function ownKeys$2(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
3445
3445
 
3446
3446
  function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$2(Object(source), true).forEach(function (key) { _defineProperty__default['default'](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$2(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
3447
-
3448
3447
  var InsightMetrics = function InsightMetrics() {
3449
3448
  _classCallCheck__default['default'](this, InsightMetrics);
3450
3449
 
@@ -3454,9 +3453,12 @@ var InsightMetrics = function InsightMetrics() {
3454
3453
 
3455
3454
  _defineProperty__default['default'](this, "wsTotalFailures", void 0);
3456
3455
 
3456
+ _defineProperty__default['default'](this, "instanceClientId", void 0);
3457
+
3457
3458
  this.connectionStartTimestamp = null;
3458
3459
  this.wsTotalFailures = 0;
3459
3460
  this.wsConsecutiveFailures = 0;
3461
+ this.instanceClientId = randomId();
3460
3462
  };
3461
3463
  function buildWsFatalInsight(connection, event) {
3462
3464
  return _objectSpread$2({
@@ -3488,7 +3490,8 @@ function buildWsBaseInsight(connection) {
3488
3490
  ws_total_failures: connection.insightMetrics.wsTotalFailures,
3489
3491
  request_id: connection.requestID,
3490
3492
  online: typeof navigator !== 'undefined' ? (_navigator = navigator) === null || _navigator === void 0 ? void 0 : _navigator.onLine : null,
3491
- user_agent: typeof navigator !== 'undefined' ? (_navigator2 = navigator) === null || _navigator2 === void 0 ? void 0 : _navigator2.userAgent : null
3493
+ user_agent: typeof navigator !== 'undefined' ? (_navigator2 = navigator) === null || _navigator2 === void 0 ? void 0 : _navigator2.userAgent : null,
3494
+ instance_client_id: connection.insightMetrics.instanceClientId
3492
3495
  };
3493
3496
  }
3494
3497
 
@@ -8366,7 +8369,7 @@ var StreamChat = /*#__PURE__*/function () {
8366
8369
  }, {
8367
8370
  key: "getUserAgent",
8368
8371
  value: function getUserAgent() {
8369
- return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "4.4.1");
8372
+ return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "4.4.2");
8370
8373
  }
8371
8374
  }, {
8372
8375
  key: "setUserAgent",