From e22489f06c24e001736f5c4eb6fb6d3d7d4a6383 Mon Sep 17 00:00:00 2001 From: Gary Pendergast Date: Mon, 23 Apr 2018 04:12:20 +0000 Subject: [PATCH] REST API: Remove `permalink_structure` from the index. This was originally added to allow Gutenberg to do permalink editing, but is no longer required. It's also superceded by #41014. Reverts [42142]. Fixes #42465. Built from https://develop.svn.wordpress.org/trunk@42997 git-svn-id: http://core.svn.wordpress.org/trunk@42826 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/rest-api/class-wp-rest-server.php | 19 +++++++++---------- wp-includes/version.php | 2 +- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/wp-includes/rest-api/class-wp-rest-server.php b/wp-includes/rest-api/class-wp-rest-server.php index 51183dadb1..d758a3b128 100644 --- a/wp-includes/rest-api/class-wp-rest-server.php +++ b/wp-includes/rest-api/class-wp-rest-server.php @@ -1022,16 +1022,15 @@ class WP_REST_Server { public function get_index( $request ) { // General site data. $available = array( - 'name' => get_option( 'blogname' ), - 'description' => get_option( 'blogdescription' ), - 'url' => get_option( 'siteurl' ), - 'home' => home_url(), - 'gmt_offset' => get_option( 'gmt_offset' ), - 'timezone_string' => get_option( 'timezone_string' ), - 'permalink_structure' => get_option( 'permalink_structure' ), - 'namespaces' => array_keys( $this->namespaces ), - 'authentication' => array(), - 'routes' => $this->get_data_for_routes( $this->get_routes(), $request['context'] ), + 'name' => get_option( 'blogname' ), + 'description' => get_option( 'blogdescription' ), + 'url' => get_option( 'siteurl' ), + 'home' => home_url(), + 'gmt_offset' => get_option( 'gmt_offset' ), + 'timezone_string' => get_option( 'timezone_string' ), + 'namespaces' => array_keys( $this->namespaces ), + 'authentication' => array(), + 'routes' => $this->get_data_for_routes( $this->get_routes(), $request['context'] ), ); $response = new WP_REST_Response( $available ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 570a1dee34..e3e2039c85 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '5.0-alpha-42996'; +$wp_version = '5.0-alpha-42997'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.