diff options
Diffstat (limited to 'rubocop/cop/gitlab/union.rb')
-rw-r--r-- | rubocop/cop/gitlab/union.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rubocop/cop/gitlab/union.rb b/rubocop/cop/gitlab/union.rb index c44c847657b..36ec6bb9b7f 100644 --- a/rubocop/cop/gitlab/union.rb +++ b/rubocop/cop/gitlab/union.rb @@ -5,7 +5,7 @@ module RuboCop module Gitlab # Cop that disallows the use of `Gitlab::SQL::Union`, in favour of using # the `FromUnion` module. - class Union < RuboCop::Cop::Cop + class Union < RuboCop::Cop::Base MSG = 'Use the `FromUnion` concern, instead of using `Gitlab::SQL::Union` directly' def_node_matcher :raw_union?, <<~PATTERN @@ -15,7 +15,7 @@ module RuboCop def on_send(node) return unless raw_union?(node) - add_offense(node, location: :expression) + add_offense(node) end end end |