Skip to content

Commit

Permalink
fix: Missing optional chaining (#82860)
Browse files Browse the repository at this point in the history
if `customStatsPeriod` is null/undefined, this will error.

Maybe fix JAVASCRIPT-2X8V
  • Loading branch information
Zylphrex authored Jan 3, 2025
1 parent 39a0423 commit 1962b6e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion static/app/components/stream/group.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ function BaseGroupRow({
const {period, start, end} = selection.datetime || {};

const summary =
customStatsPeriod?.label.toLowerCase() ??
customStatsPeriod?.label?.toLowerCase() ??
(!!start && !!end
? 'time range'
: getRelativeSummary(period || DEFAULT_STATS_PERIOD).toLowerCase());
Expand Down

0 comments on commit 1962b6e

Please sign in to comment.