diff --git a/_plugins/flavor_selector.rb b/_plugins/flavor_selector.rb index 222204b3348..8ef4a81eed2 100644 --- a/_plugins/flavor_selector.rb +++ b/_plugins/flavor_selector.rb @@ -8,9 +8,12 @@ # open in a new window. module FlavorSelector class Generator < Jekyll::Generator - # Ensure we run after JekyllRedirectFrom, so that if cockroachcloud links to - # a page that *redirects* to the cockroachdb docs, we rewrite that link. - priority :lowest + # Ordering requirements: + # - Run after JekyllRedirectFrom, so that if cockroachcloud links to + # a page that *redirects* to the cockroachdb docs, we rewrite that link. + # - Run before JekyllVersions, so that it doesn't see pages that don't + # apply to this flavor. + priority :low def initialize(config) @config = config diff --git a/_plugins/versions/generator.rb b/_plugins/versions/generator.rb index 5b148ff144a..2a7565dd4b1 100644 --- a/_plugins/versions/generator.rb +++ b/_plugins/versions/generator.rb @@ -1,7 +1,10 @@ module JekyllVersions class JekyllGenerator < Jekyll::Generator - # Ensure we run after JekyllRedirectFrom so we can apply version aliases - # (e.g. stable) to redirects. + # Ordering requirements: + # - Run after JekyllRedirectFrom so we can apply version aliases + # (e.g. stable) to redirects. + # - Run after FlavorSelector, so that we don't see pages that don't + # apply to this flavor. priority :lowest def initialize(config)