/**
  * Return if the page is indexable - by default all pages are indexable, you can override this by implementing
  * the IndexableInterface on your page entity and returning false in the isIndexable method.
  *
  * @param HasNodeInterface $page
  *
  * @return boolean
  */
 protected function isIndexable(HasNodeInterface $page)
 {
     // If the page doesn't implement IndexableInterface interface or it returns true on isIndexable, index the page
     return !$page instanceof IndexableInterface || $page->isIndexable();
 }