Allow current way to write respond_to blocks
Not sure exactly since when, but we've started to get rubocop failures when using the pattern: respond_to do |format| format.js end We've been using this pattern for ages, so maybe a recent version of Rubocop introduced a change that made it report it. In any case, this is easier to read than respond_to(&:js), so we're allowing it.
This commit is contained in:
@@ -594,6 +594,8 @@ Style/StringLiteralsInInterpolation:
|
|||||||
|
|
||||||
Style/SymbolProc:
|
Style/SymbolProc:
|
||||||
Enabled: true
|
Enabled: true
|
||||||
|
AllowedMethods:
|
||||||
|
- respond_to
|
||||||
|
|
||||||
Style/TrailingCommaInArrayLiteral:
|
Style/TrailingCommaInArrayLiteral:
|
||||||
Enabled: true
|
Enabled: true
|
||||||
|
|||||||
Reference in New Issue
Block a user