You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I try to autocorrect the following code with both Rails/EagerEvaluationLogMessage and Style/MethodCallWithArgsParentheses enabled, it seems to be converted to the wrong code.
Rails.logger.debug"foo#{bar}"
Maybe this is because the 2 correctors are created simultaneously and applied at once.
I don't know how to work around this. Could it be possible to declare information at cop class side that its corrector should be calculated after other autocorrection has been applied?
…tionLogMessage`
Fixesrubocop#782.
This PR fixes an incorrect autocorrect for `Rails/EagerEvaluationLogMessage`
when using `Style/MethodCallWithArgsParentheses`'s autocorrection together.
…tionLogMessage`
Fixesrubocop#782.
This PR fixes an incorrect autocorrect for `Rails/EagerEvaluationLogMessage`
when using `Style/MethodCallWithArgsParentheses`'s autocorrection together.
If I try to autocorrect the following code with both
Rails/EagerEvaluationLogMessage
andStyle/MethodCallWithArgsParentheses
enabled, it seems to be converted to the wrong code.Maybe this is because the 2 correctors are created simultaneously and applied at once.
I don't know how to work around this. Could it be possible to declare information at cop class side that its corrector should be calculated after other autocorrection has been applied?
Expected behavior
Actual behavior
Steps to reproduce the problem
First, prepare the following set of files...
and then run the following command:
RuboCop version
I confirmed this behavior in the following environment:
The text was updated successfully, but these errors were encountered: