From e476f6cc0a019893e89b3d3da38099cc1b94bd40 Mon Sep 17 00:00:00 2001 From: Ian Dunn Date: Wed, 18 Oct 2023 11:05:25 -0700 Subject: [PATCH] Events: Specify API key for map (#1094) This is required after https://github.com/WordPress/wporg-mu-plugins/commit/a6027d62d44261269bc7afadc8fdef1277b3919e --- .../blocks/events-landing-page/events-landing-page.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/public_html/wp-content/themes/wporg-events-2023/blocks/events-landing-page/events-landing-page.php b/public_html/wp-content/themes/wporg-events-2023/blocks/events-landing-page/events-landing-page.php index 56fb85572e..3878b30f57 100644 --- a/public_html/wp-content/themes/wporg-events-2023/blocks/events-landing-page/events-landing-page.php +++ b/public_html/wp-content/themes/wporg-events-2023/blocks/events-landing-page/events-landing-page.php @@ -48,5 +48,7 @@ function render_events_landing_page( array $block_attributes, string $content ): return 'No events available'; } + $map_options['apiKey'] = 'production' === wp_get_environment_type() ? 'WORDCAMP_PROD_GOOGLE_MAPS_API_KEY' : 'WORDCAMP_DEV_GOOGLE_MAPS_API_KEY'; + return do_blocks( '' ); }