-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Non Nil in boolean methods #946
Comments
Such distinction seems irrelevant to me. The check can be refined, of course, as this would mostly resolve the only actual problem with it (which we discussed with @yujinakayama yesterday): def value_set?
!@some_boolean.nil?
end |
Sorry - I got a mistake in my first example.. I fixed it. |
I share @geniou views. |
Done. |
💙 |
thanks |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In my opinion a method with a
?
at the end should return a boolean value, but if I write code likeor
I get a message from rubocop. I know, that
should work as well, but I would expect the return of this method to be a boolean - not an user object.
Is there an idea, without disabling this cop?
The text was updated successfully, but these errors were encountered: