Skip to content

CAT 031

unurgunite edited this page Jul 11, 2026 · 3 revisions

CAT-031 — values.includes? → has_value?

Field Value
Severity info
Confidence high
Auto-fix

values.includes? → has_value? — Use has_value? instead of .values.includes? to check value existence without allocating an array.

Bad code

hash.values.includes?("target")

Clone this wiki locally