Notice: register_rest_route was called incorrectly. The REST API route definition for yoast/v1/get_head is missing the required permission_callback a
The site I'm working on is showing this issue on the posts/pages on the dashboard.
"Notice: register_rest_route was called incorrectly. The REST API route definition for yoast/v1/get_head is missing the required permission_callback argument. For REST API routes that are intended to be public, use __return_true as the permission callback. "
I just updated to WP 5.7.2 and the Yoast SEO Premium is version 14.4.1.
Does anyone know how to address this?
Solutions
The
permission_callback
is required since WordPress 5.5, maybe if you update Yoast SEO the issue can get fixed, and if you can't update, I'll recommend disabling the WP_DEBUG from your
wp-config.php
file like this:
define('WP_DEBUG', false)
See
REST API
changes in WordPress 5.5 - section 'permission_callback'
Similar questions
Notice: wp_enqueue_script was called incorrectly
So I'm busy in Wordpress. I have a theme for the site and all. It's all working fine. Then I want to activate the new theme. BENG BENG, white screen of death. I debugged and this is the error: Line 2944 is just the line that throws an error. I already checked that. Anyone ever experienced and solved this? EDIT: Referencing lines:
Notice: wp_enqueue_script was called incorrectly. in Wordpress debug mode
The Code above is working and my postlike system is working fine like that, however Im getting Notice: wp_enqueue_script was called incorrectly. in wordpress debug mode but its working. When I try to do it as a function in the right way the like buttons not working the javascript is broken and also when I try to add this only for single pages using...
Woocommerce - internal server error: Notice: id was called incorrectly
My site has a problem. On checkout I get the Internal server error. I have read almost all the solutions provided on forums and even on this forum but none proved to solve this problem. Here is the error log below. Notice: id was called incorrectly. Order properties should not be accessed directly. Backtrace: require(‘wp-blog-header.php’), require_...
Getting notice is wordpress "WP_Scripts::localize was called incorrectly"
Complete message: Notice: WP_Scripts::localize was called incorrectly. The $l10n parameter must be an array. To pass arbitrary data to scripts, use the wp_add_inline_script() function instead. Please see Debugging in WordPress for more information. (This message was added in version 5.7.0.) in /home3/dduconne/public_html/wp-includes/functions.php o...
Also ask