We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using autocorrect for Rails/ActionOrder leaves comments behind, and making misplaced comments.
Rails/ActionOrder
It seems comments just before methods (with no empty line) should move with following methods.
# frozen_string_literal: true class TestController < BaseController def index end # comment for edit def edit end end
# frozen_string_literal: true class TestController < BaseController # comment for edit def index end def edit end end
rubocop -a for following file
rubocop -a
# frozen_string_literal: true class TestController < BaseController # comment for edit def edit end def index end end
$ [bundle exec] rubocop -V 1.37.1 (using Parser 3.1.2.1, rubocop-ast 1.23.0, running on ruby 2.7.6) [x86_64-linux] - rubocop-rails 2.17.1
The text was updated successfully, but these errors were encountered:
I can also reproduce this.
Sorry, something went wrong.
[Fix rubocop#837] Fix incorrect autocorrection of Rails/ActionOrder…
117f5b2
… about comments
Successfully merging a pull request may close this issue.
Using autocorrect for
Rails/ActionOrder
leaves comments behind, and making misplaced comments.It seems comments just before methods (with no empty line) should move with following methods.
Expected behavior
Actual behavior
Steps to reproduce the problem
rubocop -a
for following fileRuboCop version
The text was updated successfully, but these errors were encountered: