From 0801acbdd8b95a1287fc246723747688adfc57da Mon Sep 17 00:00:00 2001 From: Ryan McCue Date: Wed, 18 Nov 2015 07:24:28 +0000 Subject: [PATCH] REST API: Remove redundant "0" parameter. This is just an artifact of how we parse the URL, and is already available via $request->get_route() Props danielbachhuber. Fixes #34647. Built from https://develop.svn.wordpress.org/trunk@35659 git-svn-id: http://core.svn.wordpress.org/trunk@35623 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/rest-api/class-wp-rest-server.php | 2 ++ wp-includes/version.php | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/wp-includes/rest-api/class-wp-rest-server.php b/wp-includes/rest-api/class-wp-rest-server.php index b094634985..37c697e43f 100644 --- a/wp-includes/rest-api/class-wp-rest-server.php +++ b/wp-includes/rest-api/class-wp-rest-server.php @@ -789,6 +789,8 @@ class WP_REST_Server { } if ( ! is_wp_error( $response ) ) { + // Remove the redundant preg_match argument. + unset( $args[0] ); $request->set_url_params( $args ); $request->set_attributes( $handler ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 8fa69a7d14..2696c569f1 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.4-beta4-35658'; +$wp_version = '4.4-beta4-35659'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.