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
.none()
I have the code:
module ApplicationHelper def my_method User.where(id: nil) User.where(id: 0) User.where(id: []) User.where(id: {}) User.limit(nil) User.limit(0) end end
I run rubocop and don't get any offences:
ydakuka@yauhenid:~/Work/project$ bin/rails_docker rubocop app/helpers/application_helper.rb Inspecting 1 file . 1 file inspected, no offenses detected
I expected to receive the following code:
module ApplicationHelper def my_method User.none # for all cases end end
The text was updated successfully, but these errors were encountered:
This seems to be a matter of style. Please open a proposal in the style guide first. If accepted there, it can be provided as a cop. https://github.com/rubocop/rails-style-guide
Note that while these will return the same results in most cases, they do not behave strictly the same.
Sorry, something went wrong.
rubocop/rails-style-guide#337
No branches or pull requests
Actual behavior
I have the code:
I run rubocop and don't get any offences:
Expected behavior
I expected to receive the following code:
The text was updated successfully, but these errors were encountered: