Skip to content
New issue

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

False positive for Style/VariableName cop #1286

Closed
sferik opened this issue Aug 19, 2014 · 0 comments
Closed

False positive for Style/VariableName cop #1286

sferik opened this issue Aug 19, 2014 · 0 comments

Comments

@sferik
Copy link
Contributor

sferik commented Aug 19, 2014

The following code causes the Style/VariableName cop to emit the following offense: Use snake_case for variables.

fields.select { |field| self == field.group }

Moving self to the right-hand side causes the offense not to be reported:

fields.select { |field| field.group == self}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant