mirror of
https://gitlab.com/gitlab-org/gitlab-foss.git
synced 2025-08-03 16:04:30 +00:00
19 lines
466 B
Ruby
19 lines
466 B
Ruby
# frozen_string_literal: true
|
|
|
|
module RuboCop
|
|
module Cop
|
|
module Gitlab
|
|
# Cop that prevents the use of `without_reactive_cache`
|
|
class WithoutReactiveCache < RuboCop::Cop::Base
|
|
MSG = 'without_reactive_cache is for debugging purposes only. Please use with_reactive_cache.'
|
|
|
|
RESTRICT_ON_SEND = %i[without_reactive_cache].freeze
|
|
|
|
def on_send(node)
|
|
add_offense(node.loc.selector)
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|