From ccf1fd6f9a21e4fc1393f772f8015b8e2de65358 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Se=CC=81rgio=20Ramos?= Date: Tue, 22 Aug 2017 14:34:57 +0100 Subject: [PATCH] feat(cp-frontend): don't show env toggle when no variables set --- .../src/components/manifest/edit-or-create.js | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/packages/cp-frontend/src/components/manifest/edit-or-create.js b/packages/cp-frontend/src/components/manifest/edit-or-create.js index a66f36d5..6c3ad923 100644 --- a/packages/cp-frontend/src/components/manifest/edit-or-create.js +++ b/packages/cp-frontend/src/components/manifest/edit-or-create.js @@ -358,18 +358,20 @@ export const Review = ({ Image: {config.image} - - onEnvironmentToggle(name)} - > - Environment variables{' '} - - - {environmentToggles[name] + {config.environment && config.environment.length ? : null} + {config.environment && config.environment.length ? + onEnvironmentToggle(name)} + > + Environment variables{' '} + + + : null} + {config.environment && config.environment.length && environmentToggles[name] ? : null}