tobiholic
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: status 401 on page loadI checked my /plugins folder for rest_enabled, and in breakdance/plugin/bloat-eliminator (breakdance page builder) I found the following:
function disableJSONRestAPI()
{
// Remove the REST API lines from the HTML Header
remove_action('wp_head', 'rest_output_link_wp_head', 10);
// completely disable json api
// Filters for WP-API version 1.x
add_filter('json_enabled', '__return_false');
add_filter('json_jsonp_enabled', '__return_false');
// Filters for WP-API version 2.x
add_filter('rest_enabled', '__return_false');
add_filter('rest_jsonp_enabled', '__return_false');
}I don’t want to disable the breakdance plugin, since that would shut down the site.
add_filter('rest_enabled', '_return_false');Could that be a the cause of this issue?
- This reply was modified 7 months, 3 weeks ago by tobiholic.
Forum: Fixing WordPress
In reply to: status 401 on page load@jluizsouzadev Thanks for the comment, helps a lot! I enabled debugging, following log I have in my debug.log:
[10-Aug-2025 08:54:35 UTC] PHP Deprecated: The hook rest_enabled has been deprecated since version 4.7.0! Use rest_authentication_errors instead. The REST API can no longer be completely disabled; however, the rest_authentication_errors filter can be used to restrict access to the API. In /home/www/public/wp-includes/functions.php on line 6121.So it feels like that one of the plugins is using an old hook rest_enabled. I am trying to find out which plugin it is now by turning them all off.
Any comments / tipps still appreciated! Thanks for the quick help guys.
Forum: Fixing WordPress
In reply to: status 401 on page load@threadi thanks for your quick reply, really appreciated.
But I am not using GlotPress plugin on this wordpress Website. I will check all plugins and deactivate the ones I am not using.