Inspectopedia 2024.3 Help

Code style issues

Array of string literals instead of '%w'   New in this release

Reports arrays of string literals that can be replaced with %w.

Block used instead of method reference   New in this release

Reports blocks that can be replaced with method references.

Class variable usage   New in this release

Reports the use of class variables.

Complex call chain   New in this release

Reports chained calls that can be simplified with the safe navigation operator (&.).

Conditional expression with parentheses   New in this release

Reports conditional expressions with parentheses inside if, elsif, unless, while, and until statements.

Hash with strings as keys   New in this release

Reports hashes with strings as keys.

Incorrect parentheses in method definition   New in this release

Reports method definitions with the incorrect parentheses style.

Interpolated variable without braces   New in this release

Reports interpolated variables (instance or global) without braces in expression substitutions.

Legacy hash syntax   New in this release

Reports hashes which use the hash rocket style that can be converted to the ruby 1.9+ style.

Redundant parentheses in no-arg method call   New in this release

Reports no-arg method calls with parentheses.

Unnecessary use of double quotes in string   New in this release

Reports double-quoted strings that can be converted to single-quoted.

Whitespace before parentheses in method call   New in this release

Reports method calls (including yield) with whitespace before its parentheses.

Last modified: 11 September 2024