وردپرس

HotFix for: /src/presenters/meta-description-presenter.php:60 | WordPress.org


I have 2 similar installations with Yoast SEO 22.2 and one of these started to produce in PHP error.log:

PHP Fatal error: Uncaught TypeError: stripslashes(): Argument #1 ($string) must be of type string, array given in …/wp-content/plugins/wordpress-seo/src/presenters/meta-description-presenter.php:60

HotFix for this is to replace this row of code with:

if(is_string($meta_description)) {
$meta_description = $this->helpers->string->strip_all_tags( \stripslashes( $meta_description ) );
}elseif(is_array($meta_description)) {
foreach($meta_description AS $key => $value) {
$meta_description = [$key] = $this->helpers->string->strip_all_tags( \stripslashes( $value ) );
}
}else{
// Todo…
}

The installation is running at WordPress 6.4.3 with custom child Theme based on Avada 7.11.6

It you find this to be an Yoast SEO plugin issue, I will be pleased with regular fix of this problem directly inside Yoast SEO plugin.

پایان/ مرجع وب و فناوری

مشاهده پاسخ های این مطلب
———————————————
این مطلب از سایت انجمن وردپرس گردآوری شده است و کلیه حقوق مطلق به انجمن وردپرس می باشد در صورت مغایرت و یا بروز مشکل اطلاع دهید تا حذف گردد

منبع: انجمن وردپرس

دکمه بازگشت به بالا