diff --git a/Gemfile.lock b/Gemfile.lock index 647e787cd1..567e8569c4 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -23,7 +23,7 @@ GEM powerpack (0.1.1) rainbow (3.0.0) rake (12.3.0) - rubocop (0.55.0) + rubocop (0.56.0) parallel (~> 1.10) parser (>= 2.5) powerpack (~> 0.1) diff --git a/lib/faker/star_wars.rb b/lib/faker/star_wars.rb index f2db5a7d4e..48683a6a35 100644 --- a/lib/faker/star_wars.rb +++ b/lib/faker/star_wars.rb @@ -74,7 +74,7 @@ def quote(character = nil) character = k.to_s if v.include?(character) end - unless quoted_characters.keys.include?(character.to_sym) + unless quoted_characters.key?(character.to_sym) raise ArgumentError, "Character for quotes can be left blank or #{quoted_characters.keys.join(', ')}" end end diff --git a/lib/helpers/unique_generator.rb b/lib/helpers/unique_generator.rb index 35ea0f2772..3ad63f6c77 100644 --- a/lib/helpers/unique_generator.rb +++ b/lib/helpers/unique_generator.rb @@ -6,7 +6,7 @@ def initialize(generator, max_retries) @previous_results = Hash.new { |hash, key| hash[key] = Set.new } end - # rubocop:disable Style/MethodMissing + # rubocop:disable Style/MethodMissingSuper def method_missing(name, *arguments) @max_retries.times do result = @generator.public_send(name, *arguments) @@ -19,7 +19,7 @@ def method_missing(name, *arguments) raise RetryLimitExceeded end - # rubocop:enable Style/MethodMissing + # rubocop:enable Style/MethodMissingSuper def respond_to_missing?(method_name, include_private = false) method_name.to_s.start_with?('faker_') || super