wordpress-seo
wordpress-seo copied to clipboard
Use `wp_is_serving_rest_request` once we drop support for WP 6.4
WP 6.5 introduced the wp_is_serving_rest_request() function (and the wp_is_rest_endpoint() function) that can rcompletely replace our Request_Helper class, so let's do that and use the core wp_is_serving_rest_request() function instead.
Things to take note of:
- check references of the
Request_Helperclass and theREST_REQUESTdefine, in all our plugins, so we replace all of them. - check if in some cases,
wp_is_rest_endpoint()is the more appropriate function to use