Sha256: e2d4bb71646acc219048ce0515c7be36d17e7a263bfcac34875372b18fe11dbd

Contents?: true

Size: 502 Bytes

Versions: 3

Compression:

Stored size: 502 Bytes

Contents

module Gitlab
  module Styles
    module Rubocop
      module Cop
        # Cop that prevents the use of `without_reactive_cache`
        class WithoutReactiveCache < RuboCop::Cop::Cop
          MSG = 'without_reactive_cache is for debugging purposes only. Please use with_reactive_cache.'.freeze

          def on_send(node)
            return unless node.children[1] == :without_reactive_cache

            add_offense(node, location: :selector)
          end
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
gitlab-styles-3.3.0 lib/gitlab/styles/rubocop/cop/without_reactive_cache.rb
gitlab-styles-3.2.0 lib/gitlab/styles/rubocop/cop/without_reactive_cache.rb
gitlab-styles-3.1.0 lib/gitlab/styles/rubocop/cop/without_reactive_cache.rb