Yoast\WP\SEO\Actions\Indexing
Abstract_Link_Indexing_Action::index() public Yoast 1.0
Builds links for indexables which haven't had their links indexed yet.
{} Это метод класса: Abstract_Link_Indexing_Action{}
Хуков нет.
Возвращает
SEO_Links[]. The created SEO links.
Использование
$Abstract_Link_Indexing_Action = new Abstract_Link_Indexing_Action(); $Abstract_Link_Indexing_Action->index();
Код Abstract_Link_Indexing_Action::index() Abstract Link Indexing Action::index Yoast 15.6.2
public function index() {
$objects = $this->get_objects();
$indexables = [];
foreach ( $objects as $object ) {
$indexable = $this->repository->find_by_id_and_type( $object->id, $object->type );
$this->link_builder->build( $indexable, $object->content );
$indexable->save();
$indexables[] = $indexable;
}
\delete_transient( static::UNINDEXED_COUNT_TRANSIENT );
return $indexables;
}