Skip to content

Commit

Permalink
Hide the search page from sidebar generation
Browse files Browse the repository at this point in the history
Could cause issues if the user wants to document their search page, maybe we tie it into the create_search_page config option? Because if they have a custom search page, they would want to disable that feature, and then this should also be disabled.
  • Loading branch information
caendesilva committed Dec 13, 2023
1 parent 70236af commit 0a1a0c0
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ protected function __construct()
protected function run(): void
{
DocumentationPage::all()->each(function (DocumentationPage $page): void {
if (! in_array($page->identifier, Config::getArray('docs.exclude_from_search', []))) {
if (! in_array($page->identifier, array_merge(Config::getArray('docs.exclude_from_search', []), ['search']))) {
$this->index->push($this->generatePageEntry($page));
}
});
Expand Down

0 comments on commit 0a1a0c0

Please sign in to comment.