app/helpers/privacy_controls_helper.rb
Avoid the use of the case equality operator ===
. Open
Open
if !item.new_record? && item.file_private? === false
- Read upRead up
- Exclude checks
This cop checks for uses of the case equality operator(===).
Example:
# bad
Array === something
(1..100) === 7
/something/ === some_string
# good
something.is_a?(Array)
(1..100).include?(7)
some_string =~ /something/