All issues
Anti-pattern
Bug risk
Coverage
Documentation
Performance
Secrets
Security
Style
Type check
casecmp
Case-insensitive string comparison can be done more efficiently using casecmp.
str.downcase == 'abc' str.upcase.eql? 'ABC' 'abc' == str.downcase 'ABC'.eql? str.upcase
str.casecmp('ABC').zero? 'abc'.casecmp(str).zero?