From fcedd310b9cf1196793ae634dc7ea3f0a1c04fcc Mon Sep 17 00:00:00 2001 From: Jussiles Date: Wed, 6 Sep 2023 15:15:46 +0300 Subject: [PATCH 1/3] UHF-8081: remove setting elastic proxy url from subtheme. --- public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme b/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme index ba96a1e94..592a77ade 100644 --- a/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme +++ b/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme @@ -70,12 +70,8 @@ function hdbt_subtheme_preprocess_views_view__project_list(&$variables) { /** * Implements hook_preprocess_HOOK(). */ -function hdbt_subtheme_preprocess_node(array &$variables) { - $config = \Drupal::config('elastic_proxy.settings'); - if ($config->get('elastic_proxy_url')) { - $variables['#attached']['drupalSettings']['helfi_kymp_district_project_search']['elastic_proxy_url'] = $config->get('elastic_proxy_url'); - } - +function hdbt_subtheme_preprocess_node(array &$variables) +{ // On project nodes print out the districts even if they are unpublished. if ($variables['node']->getType() === 'project') { $node = $variables['node']; From 1708b4db648c4220581baefef2b531f0b999b721 Mon Sep 17 00:00:00 2001 From: Jussiles Date: Wed, 6 Sep 2023 15:16:12 +0300 Subject: [PATCH 2/3] UHF-8081: add sentry dsn env config. --- public/sites/default/all.settings.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/public/sites/default/all.settings.php b/public/sites/default/all.settings.php index dc48c4ed9..268137c4e 100644 --- a/public/sites/default/all.settings.php +++ b/public/sites/default/all.settings.php @@ -29,3 +29,6 @@ // Elastic proxy URL. $config['elastic_proxy.settings']['elastic_proxy_url'] = getenv('ELASTIC_PROXY_URL'); + +// Sentry DSN for React. +$config['react_search.settings']['sentry_dsn_react'] = getenv('SENTRY_DSN_REACT'); From f55f394d5d2d4796f2be2b48806f3cd2cd35cbff Mon Sep 17 00:00:00 2001 From: Jussiles Date: Wed, 6 Sep 2023 15:20:56 +0300 Subject: [PATCH 3/3] UHF-8081: fix phpcs error. --- public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme b/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme index 592a77ade..245cee852 100644 --- a/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme +++ b/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme @@ -70,8 +70,7 @@ function hdbt_subtheme_preprocess_views_view__project_list(&$variables) { /** * Implements hook_preprocess_HOOK(). */ -function hdbt_subtheme_preprocess_node(array &$variables) -{ +function hdbt_subtheme_preprocess_node(array &$variables) { // On project nodes print out the districts even if they are unpublished. if ($variables['node']->getType() === 'project') { $node = $variables['node'];