Avoid Use Of The “==” Operator

< 1 min read

Impact Area

Manageability

Severity

Medium

Affected Element

Lightning

Rule ID #

SF-0070

Impact #

Using == in conditions may lead to unexpected results, as the variables are automatically casted to be of the same type.

Remediation #

Use the === operator to evaluate conditions.

Time to fix #

30 min

References #

See the PMD documentation article: EqualComparison.

Updated on March 21, 2025
Was it helpful ?