Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'rubocop/cop/gitlab/namespaced_class.rb')
-rw-r--r--rubocop/cop/gitlab/namespaced_class.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/rubocop/cop/gitlab/namespaced_class.rb b/rubocop/cop/gitlab/namespaced_class.rb
index ce46e055c21..07e3fb8975f 100644
--- a/rubocop/cop/gitlab/namespaced_class.rb
+++ b/rubocop/cop/gitlab/namespaced_class.rb
@@ -34,7 +34,7 @@ module RuboCop
#
# class Gitlab::MyDomain::MyClass
# end
- class NamespacedClass < RuboCop::Cop::Cop
+ class NamespacedClass < RuboCop::Cop::Base
MSG = 'Classes must be declared inside a module indicating a product domain namespace. For more info: https://gitlab.com/gitlab-org/gitlab/-/issues/321982'
# These namespaces are considered top-level semantically.
@@ -51,7 +51,7 @@ module RuboCop
# Remove class name because it's not a domain namespace.
add_potential_domain_namespace(node) { _1.pop }
- add_offense(node) if domain_namespaces.none?
+ add_offense(node.loc.name) if domain_namespaces.none?
end
private