Skip to content

Commit

Permalink
fix: only measure start from snapshot data (#26735)
Browse files Browse the repository at this point in the history
  • Loading branch information
pauldambra authored Dec 6, 2024
1 parent b5533ff commit 5fb09e4
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -980,6 +980,10 @@ export const sessionRecordingDataLogic = kea<sessionRecordingDataLogicType>([
const eventStart = meta?.start_time ? dayjs(meta.start_time) : null
const snapshotStart = firstSnapshot ? dayjs(firstSnapshot.timestamp) : null

if (snapshotStart && eventStart) {
return snapshotStart
}

return snapshotStart || eventStart
},
],
Expand All @@ -992,7 +996,7 @@ export const sessionRecordingDataLogic = kea<sessionRecordingDataLogicType>([

// whichever is latest
if (eventEnd && snapshotEnd) {
return eventEnd.isAfter(snapshotEnd) ? eventEnd : snapshotEnd
return snapshotEnd
}
return eventEnd || snapshotEnd
},
Expand Down

0 comments on commit 5fb09e4

Please sign in to comment.