Browse Source

fix(replays): show right time on breadcrumbs (#35514)

### Description 

Due to the fact we are using different timezones, some users with timezones like EST (-5) are showing the wrong timestamp.

Fixes: #35114 

### Screenshots

Before:

![image](https://user-images.githubusercontent.com/14813235/172877111-b68580ea-a52d-47d1-8d50-d72af26b83d7.png)

After:

![image](https://user-images.githubusercontent.com/14813235/172877226-8559a6eb-0dbd-4700-a69b-80a3aa4be133.png)
Daian Scuarissi 2 years ago
parent
commit
6347798637
1 changed files with 1 additions and 1 deletions
  1. 1 1
      static/app/components/replays/utils.tsx

+ 1 - 1
static/app/components/replays/utils.tsx

@@ -29,7 +29,7 @@ export function relativeTimeInMs(timestamp: moment.MomentInput, diffMs: number):
 }
 
 export function showPlayerTime(timestamp: string, relativeTime: number): string {
-  return moment(relativeTimeInMs(timestamp, relativeTime)).format(TIME_FORMAT);
+  return moment.utc(relativeTimeInMs(timestamp, relativeTime)).format(TIME_FORMAT);
 }
 
 // TODO: move into 'sentry/utils/formatters'