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.../httpdocs/clone/wp-conte.../plugins/wordpres.../admin/metabox
File: class-metabox-analysis-inclusive-language.php
<?php
[0] Fix | Delete
/**
[1] Fix | Delete
* WPSEO plugin file.
[2] Fix | Delete
*
[3] Fix | Delete
* @package WPSEO\Admin\Metabox
[4] Fix | Delete
*/
[5] Fix | Delete
[6] Fix | Delete
/**
[7] Fix | Delete
* Represents the inclusive language analysis.
[8] Fix | Delete
*/
[9] Fix | Delete
class WPSEO_Metabox_Analysis_Inclusive_Language implements WPSEO_Metabox_Analysis {
[10] Fix | Delete
[11] Fix | Delete
/**
[12] Fix | Delete
* Whether this analysis is enabled.
[13] Fix | Delete
*
[14] Fix | Delete
* @return bool Whether or not this analysis is enabled.
[15] Fix | Delete
*/
[16] Fix | Delete
public function is_enabled() {
[17] Fix | Delete
return $this->is_globally_enabled() && $this->is_user_enabled() && $this->is_current_version_supported()
[18] Fix | Delete
&& YoastSEO()->helpers->language->has_inclusive_language_support( WPSEO_Language_Utils::get_language( get_locale() ) );
[19] Fix | Delete
}
[20] Fix | Delete
[21] Fix | Delete
/**
[22] Fix | Delete
* Whether or not this analysis is enabled by the user.
[23] Fix | Delete
*
[24] Fix | Delete
* @return bool Whether or not this analysis is enabled by the user.
[25] Fix | Delete
*/
[26] Fix | Delete
public function is_user_enabled() {
[27] Fix | Delete
return ! get_the_author_meta( 'wpseo_inclusive_language_analysis_disable', get_current_user_id() );
[28] Fix | Delete
}
[29] Fix | Delete
[30] Fix | Delete
/**
[31] Fix | Delete
* Whether or not this analysis is enabled globally.
[32] Fix | Delete
*
[33] Fix | Delete
* @return bool Whether or not this analysis is enabled globally.
[34] Fix | Delete
*/
[35] Fix | Delete
public function is_globally_enabled() {
[36] Fix | Delete
return WPSEO_Options::get( 'inclusive_language_analysis_active', false );
[37] Fix | Delete
}
[38] Fix | Delete
[39] Fix | Delete
/**
[40] Fix | Delete
* Whether the inclusive language analysis should be loaded in Free.
[41] Fix | Delete
*
[42] Fix | Delete
* It should always be loaded when Premium is not active. If Premium is active, it depends on the version. Some Premium
[43] Fix | Delete
* versions also have inclusive language code (when it was still a Premium only feature) which would result in rendering
[44] Fix | Delete
* the analysis twice. In those cases, the analysis should be only loaded from the Premium side.
[45] Fix | Delete
*
[46] Fix | Delete
* @return bool Whether or not the inclusive language analysis should be loaded.
[47] Fix | Delete
*/
[48] Fix | Delete
private function is_current_version_supported() {
[49] Fix | Delete
$is_premium = YoastSEO()->helpers->product->is_premium();
[50] Fix | Delete
$premium_version = YoastSEO()->helpers->product->get_premium_version();
[51] Fix | Delete
[52] Fix | Delete
return ! $is_premium
[53] Fix | Delete
|| version_compare( $premium_version, '19.6-RC0', '>=' )
[54] Fix | Delete
|| version_compare( $premium_version, '19.2', '==' );
[55] Fix | Delete
}
[56] Fix | Delete
}
[57] Fix | Delete
[58] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function