diff options
author | Vasilii Iakliushin <viakliushin@gitlab.com> | 2020-08-19 15:24:25 +0300 |
---|---|---|
committer | Vasilii Iakliushin <viakliushin@gitlab.com> | 2020-09-07 18:35:42 +0300 |
commit | abdc6352e41264991c879194e1db9fd7d5db84ad (patch) | |
tree | 7c21cc1a1764674e18caf0729c54fe29154119c7 /lib | |
parent | 26e415f8e9b010ebfd574cf8ec56803c5ade3f4a (diff) |
Remove product suffix exception from internal_links checker
Issue: https://gitlab.com/gitlab-org/gitlab/-/issues/218764
Follow-up for: https://gitlab.com/gitlab-org/gitlab-docs/-/merge_requests/1070
After merging: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/39715
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/docs/link.rb | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/gitlab/docs/link.rb b/lib/gitlab/docs/link.rb index 887ba102..df19de2a 100644 --- a/lib/gitlab/docs/link.rb +++ b/lib/gitlab/docs/link.rb @@ -1,8 +1,6 @@ module Gitlab module Docs class Link - PRODUCT_SUFFIX = /-(core|starter|premium|ultimate)(-only)?/.freeze - attr_reader :link, :href, :page def initialize(link, page) @@ -65,10 +63,7 @@ module Gitlab end def destination_anchor_not_found? - # TODO: Remove me when https://gitlab.com/gitlab-org/gitlab/-/merge_requests/39715 is merged - anchor_without_suffix = anchor_name.gsub(PRODUCT_SUFFIX, '') - - !destination_page.has_anchor?(anchor_without_suffix) + !destination_page.has_anchor?(anchor_name) end end end |