Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../public_h.../wp-conte.../plugins/wordpres.../admin/import
File: class-import-plugin.php
<?php
[0] Fix | Delete
/**
[1] Fix | Delete
* WPSEO plugin file.
[2] Fix | Delete
*
[3] Fix | Delete
* @package WPSEO\Admin\Import\Plugins
[4] Fix | Delete
*/
[5] Fix | Delete
[6] Fix | Delete
/**
[7] Fix | Delete
* Class WPSEO_Import_Plugin.
[8] Fix | Delete
*
[9] Fix | Delete
* Class with functionality to import Yoast SEO settings from other plugins.
[10] Fix | Delete
*/
[11] Fix | Delete
class WPSEO_Import_Plugin {
[12] Fix | Delete
[13] Fix | Delete
/**
[14] Fix | Delete
* Holds the status of and message about imports.
[15] Fix | Delete
*
[16] Fix | Delete
* @var WPSEO_Import_Status
[17] Fix | Delete
*/
[18] Fix | Delete
public $status;
[19] Fix | Delete
[20] Fix | Delete
/**
[21] Fix | Delete
* Class with functionality to import meta data from other plugins.
[22] Fix | Delete
*
[23] Fix | Delete
* @var WPSEO_Plugin_Importer
[24] Fix | Delete
*/
[25] Fix | Delete
protected $importer;
[26] Fix | Delete
[27] Fix | Delete
/**
[28] Fix | Delete
* Import class constructor.
[29] Fix | Delete
*
[30] Fix | Delete
* @param WPSEO_Plugin_Importer $importer The importer that needs to perform this action.
[31] Fix | Delete
* @param string $action The action to perform.
[32] Fix | Delete
*/
[33] Fix | Delete
public function __construct( WPSEO_Plugin_Importer $importer, $action ) {
[34] Fix | Delete
$this->importer = $importer;
[35] Fix | Delete
[36] Fix | Delete
switch ( $action ) {
[37] Fix | Delete
case 'cleanup':
[38] Fix | Delete
$this->status = $this->importer->run_cleanup();
[39] Fix | Delete
break;
[40] Fix | Delete
case 'import':
[41] Fix | Delete
$this->status = $this->importer->run_import();
[42] Fix | Delete
break;
[43] Fix | Delete
case 'detect':
[44] Fix | Delete
default:
[45] Fix | Delete
$this->status = $this->importer->run_detect();
[46] Fix | Delete
}
[47] Fix | Delete
[48] Fix | Delete
$this->status->set_msg( $this->complete_msg( $this->status->get_msg() ) );
[49] Fix | Delete
}
[50] Fix | Delete
[51] Fix | Delete
/**
[52] Fix | Delete
* Convenience function to replace %s with plugin name in import message.
[53] Fix | Delete
*
[54] Fix | Delete
* @param string $msg Message string.
[55] Fix | Delete
*
[56] Fix | Delete
* @return string Returns message with plugin name instead of replacement variables.
[57] Fix | Delete
*/
[58] Fix | Delete
protected function complete_msg( $msg ) {
[59] Fix | Delete
return sprintf( $msg, $this->importer->get_plugin_name() );
[60] Fix | Delete
}
[61] Fix | Delete
}
[62] Fix | Delete
[63] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function