Yoast\WP\SEO\Services\Importing
Importable_Detector_Service::detect_importers()
Returns the detected importers that have data to work with.
Метод класса: Importable_Detector_Service{}
Хуков нет.
Возвращает
Массив
. The detected importers that have data to work with.
Использование
$Importable_Detector_Service = new Importable_Detector_Service(); $Importable_Detector_Service->detect_importers( $plugin, $type );
- $plugin(строка|null)
- The plugin name of the importer.
По умолчанию: null - $type(строка|null)
- The type of the importer.
По умолчанию: null
Код Importable_Detector_Service::detect_importers() Importable Detector Service::detect importers Yoast 22.4
public function detect_importers( $plugin = null, $type = null ) { $detectors = $this->filter_actions( $this->importers, $plugin, $type ); $detected = []; foreach ( $detectors as $detector ) { if ( $detector->is_enabled() && $detector->get_type() !== 'cleanup' && ! $detector->get_completed() && $detector->get_limited_unindexed_count( 1 ) > 0 ) { $detected[ $detector->get_plugin() ][] = $detector->get_type(); } } return $detected; }