diff --git a/lib/rubocop/cop/rails/redundant_presence_validation_on_belongs_to.rb b/lib/rubocop/cop/rails/redundant_presence_validation_on_belongs_to.rb index 24ed3fb494..3ef7fe7055 100644 --- a/lib/rubocop/cop/rails/redundant_presence_validation_on_belongs_to.rb +++ b/lib/rubocop/cop/rails/redundant_presence_validation_on_belongs_to.rb @@ -59,14 +59,14 @@ class RedundantPresenceValidationOnBelongsTo < Base ) PATTERN - # @!method optional_option?(node) - # Match a `belongs_to` association with an optional option in a hash + # @!method optional?(node) + # Match a `belongs_to` association with an optional option in a hash def_node_matcher :optional?, <<~PATTERN (send nil? :belongs_to _ ... #optional_option?) PATTERN # @!method optional_option?(node) - # Match an optional option in a hash + # Match an optional option in a hash def_node_matcher :optional_option?, <<~PATTERN { (hash <(pair (sym :optional) true) ...>) # optional: true