Sha256: 7bb964f8f459ee892be1f68665012356baebcb4fdbc00d91b6639fcdcd4b67c7

Contents?: true

Size: 299 Bytes

Versions: 7170

Compression:

Stored size: 299 Bytes

Contents

# frozen_string_literal: true

module RuboCop
  module Cop
    # Common functionality for cops checking if and unless expressions.
    module OnNormalIfUnless
      def on_if(node)
        return if node.modifier_form? || node.ternary?

        on_normal_if_unless(node)
      end
    end
  end
end

Version data entries

7,170 entries across 7,131 versions & 51 rubygems

Version Path
rubocop-1.5.1 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.5.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.4.2 lib/rubocop/cop/mixin/on_normal_if_unless.rb
passbase-1.2.0 vendor/bundle/ruby/2.7.0/gems/rubocop-0.66.0/lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.4.1 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.4.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.3.1 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.3.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.2.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
passbase-1.1.0 vendor/bundle/ruby/2.7.0/gems/rubocop-0.66.0/lib/rubocop/cop/mixin/on_normal_if_unless.rb
passbase-1.0.3 vendor/bundle/ruby/2.7.0/gems/rubocop-0.66.0/lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.1.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-1.0.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
passbase-1.0.2 vendor/bundle/ruby/2.7.0/gems/rubocop-0.66.0/lib/rubocop/cop/mixin/on_normal_if_unless.rb
passbase-1.0.1 vendor/bundle/ruby/2.7.0/gems/rubocop-0.66.0/lib/rubocop/cop/mixin/on_normal_if_unless.rb
passbase-1.0.0 vendor/bundle/ruby/2.7.0/gems/rubocop-0.66.0/lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-0.93.1 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-0.93.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-0.92.0 lib/rubocop/cop/mixin/on_normal_if_unless.rb
rubocop-0.91.1 lib/rubocop/cop/mixin/on_normal_if_unless.rb