function SearchPage::isDefaultSearch

Same name in other branches
  1. 9 core/modules/search/src/Entity/SearchPage.php \Drupal\search\Entity\SearchPage::isDefaultSearch()
  2. 8.9.x core/modules/search/src/Entity/SearchPage.php \Drupal\search\Entity\SearchPage::isDefaultSearch()
  3. 11.x core/modules/search/src/Entity/SearchPage.php \Drupal\search\Entity\SearchPage::isDefaultSearch()

Overrides SearchPageInterface::isDefaultSearch

1 call to SearchPage::isDefaultSearch()
SearchPage::postCreate in core/modules/search/src/Entity/SearchPage.php
Acts on a created entity before hooks are invoked.

File

core/modules/search/src/Entity/SearchPage.php, line 159

Class

SearchPage
Defines a configured search page.

Namespace

Drupal\search\Entity

Code

public function isDefaultSearch() {
    return $this->searchPageRepository()
        ->getDefaultSearchPage() == $this->id();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.