@@ -107,9 +107,6 @@ export class ReplayContainer implements ReplayContainerInterface {
107107 private _debouncedFlush : ReturnType < typeof debounce > ;
108108 private _flushLock : Promise < unknown > | null = null ;
109109
110- /** We keep this here in order to be able to connect sessions after .stop() is called. */
111- private _previousSessionId : string | undefined ;
112-
113110 /**
114111 * Is the integration currently active?
115112 */
@@ -327,7 +324,6 @@ export class ReplayContainer implements ReplayContainerInterface {
327324 this . eventBuffer = null ;
328325
329326 // Clear session from session storage
330- this . _previousSessionId = this . getSessionId ( ) ;
331327 clearSession ( this ) ;
332328 } catch ( err ) {
333329 this . _handleException ( err ) ;
@@ -570,7 +566,6 @@ export class ReplayContainer implements ReplayContainerInterface {
570566 */
571567 private _initializeSession ( sampled : Sampled , { forceSampled = false } : { forceSampled ?: boolean } = { } ) : void {
572568 const { stickySession } = this . _options ;
573- const previousSessionId = this . _previousSessionId ;
574569
575570 // If neither sample rate is > 0, then do nothing - user will need to call one of
576571 // `start()` or `startBuffering` themselves.
@@ -586,14 +581,6 @@ export class ReplayContainer implements ReplayContainerInterface {
586581 }
587582
588583 this . session = session ;
589-
590- // If previously a session was stopped, we temp. store the previousSessionId on the replay container.
591- // If this is set, we restore it when initializing a new session
592- if ( previousSessionId ) {
593- this . session . previousSessionId = previousSessionId ;
594- this . _maybeSaveSession ( ) ;
595- }
596-
597584 this . recordingMode = this . session . sampled === 'buffer' ? 'buffer' : 'session' ;
598585
599586 return ;
0 commit comments