Avoid Unreachable Code

< 1 min read

Impact Area

Manageability

Severity

Medium

Affected Element

Lightning

Rule ID #

SF-0067

Impact #

A return, break, continue, or throw statement should be the last in a block. Statements after these will never execute. This is a bug, or extremely poor style.

Remediation #

Remove any unreachable code segments.

Time to fix #

30 min

References #

See the PMD documentation article: UnreachableCode.

Updated on March 21, 2025
Was it helpful ?