diff --git a/extensions/blocks/map/map.php b/extensions/blocks/map/map.php index 8914bbdc0d7f5..d3b881be1b83e 100644 --- a/extensions/blocks/map/map.php +++ b/extensions/blocks/map/map.php @@ -26,10 +26,7 @@ function jetpack_get_mapbox_api_key() { get_current_blog_id() ); } else { - $endpoint = sprintf( - '%swpcom/v2/service-api-keys/mapbox', - rest_url() - ); + $endpoint = rest_url( 'wpcom/v2/service-api-keys/mapbox' ); } $response = wp_remote_get( esc_url_raw( $endpoint ) );