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

gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorEvan Read <eread@gitlab.com>2022-11-01 06:59:12 +0300
committerEvan Read <eread@gitlab.com>2022-11-01 06:59:40 +0300
commitb0d5c1fe2ec12365faeff0ac8c30f3815fd8ce47 (patch)
treebba9742eec637a33fb6fc905b9a2f811a6f5b110 /lib
parent9569a941cc1b69b4ebf90e7920b6ffacfc25319d (diff)
Clear RuboCop violations on anchors.rb
Diffstat (limited to 'lib')
-rw-r--r--lib/checks/anchors.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/checks/anchors.rb b/lib/checks/anchors.rb
index e93fd9a2..cfbbc980 100644
--- a/lib/checks/anchors.rb
+++ b/lib/checks/anchors.rb
@@ -1,11 +1,12 @@
# frozen_string_literal: true
Nanoc::Check.define(:internal_anchors) do
+ excluded_anchors = %w[markdown-toc offline-archives]
output_html_filenames.each do |file|
Gitlab::Docs::Page.new(file).links.each do |link|
next unless link.internal?
next unless link.to_anchor?
- next if %w(markdown-toc, offline-archives).include? link.anchor_name
+ next if excluded_anchors.include? link.anchor_name
next unless link.destination_anchor_not_found?