@sentry/replay 7.66.0-alpha.0 → 7.67.0-beta.0

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/esm/index.js CHANGED
@@ -5885,6 +5885,8 @@ function loadOrCreateSession(
5885
5885
  return createSession(sessionOptions, { previousSessionId: existingSession.id });
5886
5886
  }
5887
5887
 
5888
+ const ReplayEventTypeCustom = 5;
5889
+
5888
5890
  function isCustomEvent(event) {
5889
5891
  return event.type === EventType.Custom;
5890
5892
  }
@@ -8892,7 +8894,11 @@ class ReplayContainer {
8892
8894
  }
8893
8895
 
8894
8896
  // Session is expired, trigger a full snapshot (which will create a new session)
8895
- this._triggerFullSnapshot();
8897
+ if (this.isPaused()) {
8898
+ this.resume();
8899
+ } else {
8900
+ this._triggerFullSnapshot();
8901
+ }
8896
8902
 
8897
8903
  return false;
8898
8904
  }
@@ -8935,7 +8941,7 @@ class ReplayContainer {
8935
8941
 
8936
8942
  this.addUpdate(() => {
8937
8943
  void addEvent(this, {
8938
- type: EventType.Custom,
8944
+ type: ReplayEventTypeCustom,
8939
8945
  timestamp: breadcrumb.timestamp || 0,
8940
8946
  data: {
8941
8947
  tag: 'breadcrumb',