Closed hirowatari closed 3 months ago
I do not believe this fixes the issue. I tried
gem "rubocop-rails", github: "rubocop/rubocop-rails", ref: "afcf639"
but found the same error.
The issue is not whether it's unsafe or safe. The issue is that the cop is applying to places where it's not relevant. Namely, any methods named .upsert
. You could surely have an .upsert method calling an external API that has nothing to do with Rails.
I'm getting a false positive for Rails/SkipsModelValidations. I have other classes that have the method
upsert
.Expected behavior
No offences detected
Actual behavior
Offenses detected
Steps to reproduce the problem
bundle exec rubocop ./example.rb
output:RuboCop version