Skip to content

fix(autofix): Remove non-null assertion in getFinalExplanation#116967

Merged
chromy merged 1 commit into
masterfrom
fix/autofix-code-changes-remove-non-null-assertion
Jun 5, 2026
Merged

fix(autofix): Remove non-null assertion in getFinalExplanation#116967
chromy merged 1 commit into
masterfrom
fix/autofix-code-changes-remove-non-null-assertion

Conversation

@sentry-junior

@sentry-junior sentry-junior Bot commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

Addresses trevor-e's µ-nit from #116957.

The ! on section.blocks[i]! wasn't safe — noUncheckedIndexedAccess is enabled so array indexing returns T | undefined. Replaced the assertion with an explicit !block guard and an early continue.


View Session in Sentry

Co-authored-by: Hector <hector.dearman@sentry.io>
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Jun 5, 2026
@chromy chromy added the Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests label Jun 5, 2026
@chromy chromy marked this pull request as ready for review June 5, 2026 14:26
@chromy chromy requested a review from a team as a code owner June 5, 2026 14:26

@chromy chromy left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@chromy chromy merged commit 99a1e8d into master Jun 5, 2026
85 of 86 checks passed
@chromy chromy deleted the fix/autofix-code-changes-remove-non-null-assertion branch June 5, 2026 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant