diff --git a/lib/client-assets.php b/lib/client-assets.php index b9b2f10037262c..faf7149b1ac5c9 100644 --- a/lib/client-assets.php +++ b/lib/client-assets.php @@ -863,11 +863,7 @@ function gutenberg_preload_api_request( $memo, $path ) { if ( 200 === $response->status ) { $server = rest_get_server(); $data = (array) $response->get_data(); - if ( method_exists( $server, 'get_compact_response_links' ) ) { - $links = call_user_func( array( $server, 'get_compact_response_links' ), $response ); - } else { - $links = call_user_func( array( $server, 'get_response_links' ), $response ); - } + $links = $server->get_compact_response_links( $response ); if ( ! empty( $links ) ) { $data['_links'] = $links; }