From 068f9765c96b0c87493f8fc242e0d53fb8a83e6f Mon Sep 17 00:00:00 2001 From: Esteban Pastorino Date: Sat, 27 Mar 2021 23:22:23 +0000 Subject: [PATCH 1/3] Update to rubocop 0.90 Remove RESTRICT_ON_SEND on InvalidModelAssignment cop since it wasn't doing what we thought it did. Unitl < 0.90 it was ignored so we didn't notice. --- lib/rubocop/cop/netlify/invalid_model_assignment.rb | 1 - rubocop-netlify.gemspec | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/rubocop/cop/netlify/invalid_model_assignment.rb b/lib/rubocop/cop/netlify/invalid_model_assignment.rb index a715177..9dc226d 100644 --- a/lib/rubocop/cop/netlify/invalid_model_assignment.rb +++ b/lib/rubocop/cop/netlify/invalid_model_assignment.rb @@ -13,7 +13,6 @@ module Netlify # form.email = "bettse@netlify.com" class InvalidModelAssignment < Cop MSG = "Assigning to `attributes` will not update record" - RESTRICT_ON_SEND = [:attributes].freeze def_node_matcher :assign_attributes?, <<~PATTERN (send (send (...) :attributes) :[]= _ _) diff --git a/rubocop-netlify.gemspec b/rubocop-netlify.gemspec index e76a7ce..d267e1a 100644 --- a/rubocop-netlify.gemspec +++ b/rubocop-netlify.gemspec @@ -14,7 +14,7 @@ Gem::Specification.new do |spec| spec.license = "MIT" spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0") - spec.add_dependency "rubocop", "~> 0.72", "< 0.90" + spec.add_dependency "rubocop", "~> 0.72", "< 0.91" spec.add_development_dependency "minitest", "~> 5.10" # Specify which files should be added to the gem when it is released. From 93a6f35d8196b9d7a85d23a89646dab2b381627e Mon Sep 17 00:00:00 2001 From: Esteban Pastorino Date: Sat, 27 Mar 2021 23:27:47 +0000 Subject: [PATCH 2/3] Update to < 1.0 --- rubocop-netlify.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rubocop-netlify.gemspec b/rubocop-netlify.gemspec index d267e1a..d01d599 100644 --- a/rubocop-netlify.gemspec +++ b/rubocop-netlify.gemspec @@ -14,7 +14,7 @@ Gem::Specification.new do |spec| spec.license = "MIT" spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0") - spec.add_dependency "rubocop", "~> 0.72", "< 0.91" + spec.add_dependency "rubocop", "~> 0.72", "< 1.0" spec.add_development_dependency "minitest", "~> 5.10" # Specify which files should be added to the gem when it is released. From 39dc3cc2a3a8a27270c76680ee8093e2433bf1d6 Mon Sep 17 00:00:00 2001 From: Esteban Pastorino Date: Sat, 27 Mar 2021 23:29:33 +0000 Subject: [PATCH 3/3] Update to < 2.0 --- rubocop-netlify.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rubocop-netlify.gemspec b/rubocop-netlify.gemspec index d01d599..5d3ced0 100644 --- a/rubocop-netlify.gemspec +++ b/rubocop-netlify.gemspec @@ -14,7 +14,7 @@ Gem::Specification.new do |spec| spec.license = "MIT" spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0") - spec.add_dependency "rubocop", "~> 0.72", "< 1.0" + spec.add_dependency "rubocop", "~> 0.72", "< 2.0" spec.add_development_dependency "minitest", "~> 5.10" # Specify which files should be added to the gem when it is released.