From 46a8e2bbfc3f76b46824e86bbbf7de8a7fc45c8e Mon Sep 17 00:00:00 2001 From: Kimmo Puputti Date: Thu, 16 Aug 2018 16:58:25 +0300 Subject: [PATCH] Require an env var to show default searches --- .env-template | 1 + src/config.js | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.env-template b/.env-template index a837fdc7..f19ad98f 100644 --- a/.env-template +++ b/.env-template @@ -35,3 +35,4 @@ REACT_APP_ENV=production # REACT_APP_AVAILABILITY_ENABLED=true +REACT_APP_DEFAULT_SEARCHES_ENABLED=true diff --git a/src/config.js b/src/config.js index fcee6962..32fd24ed 100644 --- a/src/config.js +++ b/src/config.js @@ -283,7 +283,8 @@ const maps = { // Example location can be edited in the // `default-location-searches.js` file. - defaults: defaultLocationSearches, + defaults: + process.env.REACT_APP_DEFAULT_SEARCHES_ENABLED === 'true' ? defaultLocationSearches : [], }, // When fuzzy locations are enabled, coordinates on maps are