Yoast\WP\SEO\Routes
Importing_Route::get_importer()
Gets the right importer for the given arguments.
Метод класса: Importing_Route{}
Хуков нет.
Возвращает
Importing_Action_Interface|false
. The importer, or false if no importer was found.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->get_importer( $plugin, $type );
- $plugin(строка) (обязательный)
- The plugin to import from.
- $type(строка) (обязательный)
- The type of entity to import.
Код Importing_Route::get_importer() Importing Route::get importer Yoast 24.9
protected function get_importer( $plugin, $type ) { $importers = $this->importable_detector->filter_actions( $this->importers, $plugin, $type ); if ( \count( $importers ) !== 1 ) { return false; } return \current( $importers ); }