diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-revisions-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-revisions-controller.php index 78f6e115688b4..08a8479678002 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-revisions-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-revisions-controller.php @@ -407,7 +407,7 @@ public function get_item( $request ) { return new WP_Error( 'rest_post_invalid_parent', /* translators: %s: A post revision id. */ - sprintf( __( 'Parent post does not have a revision with id of "%s"' ), $revision->post_parent ), + sprintf( __( 'Parent post does not have a revision with id of "%s"' ), $request['id'] ), array( 'status' => 404 ) ); }