diff --git a/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php b/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php index 4aa893e907..dfb97f7b60 100644 --- a/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php +++ b/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php @@ -2039,7 +2039,7 @@ class WP_REST_Posts_Controller extends WP_REST_Controller { if ( $post_type_obj->hierarchical && ! empty( $post->post_parent ) ) { $links['up'] = array( - 'href' => rest_url( trailingslashit( $base ) . (int) $post->post_parent ), + 'href' => rest_url( rest_get_route_for_post( $post->post_parent ) ), 'embeddable' => true, ); } diff --git a/wp-includes/version.php b/wp-includes/version.php index c3d7d22f45..a7e6aa3b5b 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '5.9-beta2-52362'; +$wp_version = '5.9-beta2-52363'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.