From 95a6e14e4a8c7cedde34abf8a8540a99944d2c8f Mon Sep 17 00:00:00 2001 From: Warface Date: Fri, 23 Aug 2024 07:53:57 -0400 Subject: [PATCH] Update functions.php Removed wp-json stuff so spiders don't index them. Anyway there's unauthorized --- functions.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/functions.php b/functions.php index daf3bca..a5b13b6 100644 --- a/functions.php +++ b/functions.php @@ -246,6 +246,10 @@ function remove_thumbnail_dimensions( $html ){ remove_action('wp_head', 'adjacent_posts_rel_link_wp_head', 10, 0); remove_action('wp_head', 'rel_canonical'); remove_action('wp_head', 'wp_shortlink_wp_head', 10, 0); +//remove wp-json +remove_action('wp_head', 'rest_output_link_wp_head', 10); +remove_action('wp_head', 'wp_oembed_add_discovery_links', 10); +remove_action('template_redirect', 'rest_output_link_header', 11, 0); // Add Filters